Deleted Added
full compact
audump.c (189279) audump.c (196031)
1/*-
1/*-
2 * Copyright (c) 2005-2006 Robert N. M. Watson
2 * Copyright (c) 2005-2009 Robert N. M. Watson
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright

--- 7 unchanged lines hidden (view full) ---

18 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
19 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
20 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24 * SUCH DAMAGE.
25 *
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright

--- 7 unchanged lines hidden (view full) ---

18 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
19 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
20 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24 * SUCH DAMAGE.
25 *
26 * $P4: //depot/projects/trustedbsd/openbsm/tools/audump.c#8 $
26 * $P4: //depot/projects/trustedbsd/openbsm/tools/audump.c#9 $
27 */
28
29#include <bsm/libbsm.h>
30#include <string.h>
31#include <err.h>
32#include <limits.h>
33#include <stdio.h>
34#include <stdlib.h>

--- 125 unchanged lines hidden (view full) ---

160printf_classmask(au_class_t classmask)
161{
162 au_class_ent_t *c;
163 u_int32_t i;
164 int first;
165
166 first = 1;
167 for (i = 0; i < 32; i++) {
27 */
28
29#include <bsm/libbsm.h>
30#include <string.h>
31#include <err.h>
32#include <limits.h>
33#include <stdio.h>
34#include <stdlib.h>

--- 125 unchanged lines hidden (view full) ---

160printf_classmask(au_class_t classmask)
161{
162 au_class_ent_t *c;
163 u_int32_t i;
164 int first;
165
166 first = 1;
167 for (i = 0; i < 32; i++) {
168 if (classmask & (2 << i)) {
168 if (classmask & (1 << i)) {
169 if (first)
170 first = 0;
171 else
172 printf(",");
169 if (first)
170 first = 0;
171 else
172 printf(",");
173 c = getauclassnum(2 << i);
173 c = getauclassnum(1 << i);
174 if (c != NULL)
175 printf("%s", c->ac_name);
176 else
174 if (c != NULL)
175 printf("%s", c->ac_name);
176 else
177 printf("0x%x", 2 << i);
177 printf("0x%x", 1 << i);
178 }
179 }
180}
181
182static void
183audump_event(void)
184{
185 au_event_ent_t *ep;

--- 87 unchanged lines hidden ---
178 }
179 }
180}
181
182static void
183audump_event(void)
184{
185 au_event_ent_t *ep;

--- 87 unchanged lines hidden ---