Date: Tue, 7 May 2002 22:19:30 -0700 (PDT) From: "Andrew R. Reiter" <arr@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 10996 for review Message-ID: <200205080519.g485JUB23714@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://people.freebsd.org/~peter/p4db/chv.cgi?CH=10996 Change 10996 by arr@arr_shibby on 2002/05/07 22:18:33 - Add security.audit node and a child, debug, that will allow toggling of verbose debugging output when the AUDIT_DEBUG option is used. Affected files ... ... //depot/projects/trustedbsd/audit/sys/kern/kern_audit.c#37 edit Differences ... ==== //depot/projects/trustedbsd/audit/sys/kern/kern_audit.c#37 (text+ko) ==== @@ -63,12 +63,6 @@ static int audit_shutdown_flag = 0; static int audit_id = 0; -#ifdef AUDIT_DEBUG -#define audit_print_record(ar) _audit_print_record((ar)) -#else -#define audit_print_record(ar) -#endif - /* * Re-add this later when handling the decrease in the pool * size can be properly handled. @@ -76,6 +70,24 @@ * static size_t pool_size = 32; */ +SYSCTL_DECL(_security); +SYSCTL_NODE(_security, OID_AUTO, audit, CTLFLAG_RW, 0, ""); + +#ifdef AUDIT_DEBUG +int audit_debug = 0; + +SYSCTL_INT(_security_audit, OID_AUTO, debug, CTLFLAG_RW, &audit_debug, + 0, ""); + +#define audit_print_record(ar) do { \ + if (audit_debug) \ + _audit_print_record((ar)); \ +} while (0) +#else +#define audit_print_record(ar) +#endif + + audit_record_t * audit_record_init(int type, size_t evsz) { To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe p4-projects" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200205080519.g485JUB23714>