Date: Mon, 17 Oct 2005 12:27:18 GMT From: Robert Watson <rwatson@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 85429 for review Message-ID: <200510171227.j9HCRI8w056133@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=85429 Change 85429 by rwatson@rwatson_zoo on 2005/10/17 12:26:38 Integrate bsm_token.c from OpenBSM to the TrustedBSD Audit3 contrib tree: White space and style cleanups. Affected files ... .. //depot/projects/trustedbsd/audit3/contrib/openbsm/libbsm/bsm_token.c#4 integrate Differences ... ==== //depot/projects/trustedbsd/audit3/contrib/openbsm/libbsm/bsm_token.c#4 (text+ko) ==== @@ -164,7 +164,6 @@ return (NULL); } - GET_TOKEN_AREA(t, dptr, 29); if (t == NULL) return (NULL); @@ -214,7 +213,6 @@ { return (au_to_attr32(vni)); - } #endif /* !(defined(_KERNEL) || defined(KERNEL) */ @@ -238,7 +236,7 @@ } /* Determine the size of the basic unit. */ - switch(unit_type) { + switch (unit_type) { case AUR_BYTE: datasize = AUR_BYTE_SIZE; break; @@ -392,7 +390,8 @@ * token ID 1 byte * ip header 20 bytes */ -token_t *au_to_ip(struct ip *ip) +token_t * +au_to_ip(struct ip *ip) { token_t *t; u_char *dptr = NULL; @@ -545,11 +544,11 @@ } /* - * token ID 1 byte - * seconds of time 4 bytes - * milliseconds of time 4 bytes - * file name len 2 bytes - * file pathname N bytes + 1 terminating NULL byte + * token ID 1 byte + * seconds of time 4 bytes + * milliseconds of time 4 bytes + * file name len 2 bytes + * file pathname N bytes + 1 terminating NULL byte */ token_t * #if defined(KERNEL) || defined(_KERNEL) @@ -708,7 +707,8 @@ pid_t pid, au_asid_t sid, au_tid_t *tid) { - return (au_to_process32(auid, euid, egid, ruid, rgid, pid, sid, tid)); + return (au_to_process32(auid, euid, egid, ruid, rgid, pid, sid, + tid)); } /* @@ -769,8 +769,8 @@ } token_t * -au_to_process_ex(au_id_t auid, uid_t euid, gid_t egid, uid_t ruid, gid_t rgid, - pid_t pid, au_asid_t sid, au_tid_addr_t *tid) +au_to_process_ex(au_id_t auid, uid_t euid, gid_t egid, uid_t ruid, + gid_t rgid, pid_t pid, au_asid_t sid, au_tid_addr_t *tid) { return (au_to_process32_ex(auid, euid, egid, ruid, rgid, pid, sid, @@ -871,7 +871,7 @@ */ token_t * au_to_socket_ex_32(u_int16_t lp, u_int16_t rp, struct sockaddr *la, -struct sockaddr *ra) + struct sockaddr *ra) { errno = ENOTSUP; @@ -904,7 +904,7 @@ GET_TOKEN_AREA(t, dptr, 107); if (t == NULL) return (NULL); - + ADD_U_CHAR(dptr, AU_SOCK_UNIX_TOKEN); /* BSM token has two bytes for family */ ADD_U_CHAR(dptr, 0); @@ -986,7 +986,7 @@ au_to_sock_inet(struct sockaddr_in *so) { - return au_to_sock_inet32(so); + return (au_to_sock_inet32(so)); } /* @@ -1046,7 +1046,8 @@ pid_t pid, au_asid_t sid, au_tid_t *tid) { - return (au_to_subject32(auid, euid, egid, ruid, rgid, pid, sid, tid)); + return (au_to_subject32(auid, euid, egid, ruid, rgid, pid, sid, + tid)); } /* @@ -1110,6 +1111,7 @@ au_to_subject_ex(au_id_t auid, uid_t euid, gid_t egid, uid_t ruid, gid_t rgid, pid_t pid, au_asid_t sid, au_tid_addr_t *tid) { + return (au_to_subject32_ex(auid, euid, egid, ruid, rgid, pid, sid, tid)); } @@ -1263,7 +1265,7 @@ timems = tm.tv_usec/1000; /* Add the timestamp */ ADD_U_INT32(dptr, tm.tv_sec); - ADD_U_INT32(dptr, timems); /* We need time in ms */ + ADD_U_INT32(dptr, timems); /* We need time in ms. */ return (t); }
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200510171227.j9HCRI8w056133>