Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 28 Feb 2006 14:07:40 GMT
From:      Robert Watson <rwatson@FreeBSD.org>
To:        Perforce Change Reviews <perforce@freebsd.org>
Subject:   PERFORCE change 92527 for review
Message-ID:  <200602281407.k1SE7eOC029964@repoman.freebsd.org>

next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=92527

Change 92527 by rwatson@rwatson_lethe.cl.cam.ac.uk on 2006/02/28 14:07:01

	Only implement au_close() if audit system calls are available, as
	otherwise we can't submit it.  au_close_buffer() remains
	available even without audit system calls, so the remainder of
	the record construction calls remain useful.  (Linux)

Affected files ...

.. //depot/projects/trustedbsd/openbsm/libbsm/bsm_audit.c#21 edit

Differences ...

==== //depot/projects/trustedbsd/openbsm/libbsm/bsm_audit.c#21 (text+ko) ====

@@ -30,7 +30,7 @@
  * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
  * POSSIBILITY OF SUCH DAMAGE.
  *
- * $P4: //depot/projects/trustedbsd/openbsm/libbsm/bsm_audit.c#20 $
+ * $P4: //depot/projects/trustedbsd/openbsm/libbsm/bsm_audit.c#21 $
  */
 
 #include <sys/types.h>
@@ -266,11 +266,13 @@
 	pthread_mutex_unlock(&mutex);
 }
 
+#ifdef HAVE_AUDIT_SYSCALLS
 /*
  * Add the header token, identify any missing tokens.  Write out the tokens to
  * the record memory and finally, call audit.
  */
-int au_close(int d, int keep, short event)
+int
+au_close(int d, int keep, short event)
 {
 	au_record_t *rec;
 	size_t tot_rec_size;
@@ -318,6 +320,7 @@
 	au_teardown(rec);
 	return (retval);
 }
+#endif /* HAVE_AUDIT_SYSCALLS */
 
 /*
  * au_close(), except onto an in-memory buffer.  Buffer size as an argument,



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200602281407.k1SE7eOC029964>