* audit-userspace: auparse/lru.c sanity_check_queue() compile error with DEBUG @ 2017-12-18 1:19 Mor, Omri 2017-12-18 17:34 ` Steve Grubb 0 siblings, 1 reply; 4+ messages in thread From: Mor, Omri @ 2017-12-18 1:19 UTC (permalink / raw) To: linux-audit@redhat.com sanity_check_queue() attempts to call msg(), which as far as I can tell isn’t defined. It appears that this should be syslog() or audit_msg() instead. This causes compilation failure when DEBUG is defined. Omri Mor -- Linux-audit mailing list Linux-audit@redhat.com https://www.redhat.com/mailman/listinfo/linux-audit ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: audit-userspace: auparse/lru.c sanity_check_queue() compile error with DEBUG 2017-12-18 1:19 audit-userspace: auparse/lru.c sanity_check_queue() compile error with DEBUG Mor, Omri @ 2017-12-18 17:34 ` Steve Grubb 2017-12-19 19:49 ` Mor, Omri 0 siblings, 1 reply; 4+ messages in thread From: Steve Grubb @ 2017-12-18 17:34 UTC (permalink / raw) To: linux-audit; +Cc: Mor, Omri [-- Attachment #1.1: Type: text/plain, Size: 365 bytes --] On Sunday, December 17, 2017 8:19:14 PM EST Mor, Omri wrote: > sanity_check_queue() attempts to call msg(), which as far as I can tell > isn’t defined. It appears that this should be syslog() or audit_msg() > instead. > This causes compilation failure when DEBUG is defined. Thanks for reporting this. The function name is now fixed in git. -Steve [-- Attachment #1.2: Type: text/html, Size: 2152 bytes --] [-- Attachment #2: Type: text/plain, Size: 0 bytes --] ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: audit-userspace: auparse/lru.c sanity_check_queue() compile error with DEBUG 2017-12-18 17:34 ` Steve Grubb @ 2017-12-19 19:49 ` Mor, Omri 2017-12-20 21:19 ` Steve Grubb 0 siblings, 1 reply; 4+ messages in thread From: Mor, Omri @ 2017-12-19 19:49 UTC (permalink / raw) To: Steve Grubb; +Cc: linux-audit@redhat.com >> sanity_check_queue() attempts to call msg(), which as far as I can tell >> isn’t defined. It appears that this should be syslog() or audit_msg() >> instead. >> This causes compilation failure when DEBUG is defined. > > Thanks for reporting this. The function name is now fixed in git. On second look, I think it’s supposed to be syslog(), not audit_msg(). The rest of the code in auparse/lru.c calls syslog(), and audit_msg() requires a `auparse_state_t *' parameter which the current code doesn’t supply. This causes compile-time warnings and probably runtime errors later if sanity_check_queue() were to actually be run. lru.c: In function ‘sanity_check_queue’: lru.c:148:14: warning: passing argument 1 of ‘auparse_msg’ makes pointer from integer without a cast [-Wint-conversion] audit_msg(LOG_DEBUG, "%s - corruption found %u", id, i); ^ In file included from lru.c:28:0: private.h:34:6: note: expected ‘auparse_state_t * {aka struct opaque *}’ but argument is of type ‘int’ void auparse_msg(auparse_state_t *au, int priority, const char *fmt, ...) ^ lru.c:148:25: warning: passing argument 2 of ‘auparse_msg’ makes integer from pointer without a cast [-Wint-conversion] audit_msg(LOG_DEBUG, "%s - corruption found %u", id, i); ^ In file included from lru.c:28:0: private.h:34:6: note: expected ‘int’ but argument is of type ‘char *’ void auparse_msg(auparse_state_t *au, int priority, const char *fmt, ...) Omri -- Linux-audit mailing list Linux-audit@redhat.com https://www.redhat.com/mailman/listinfo/linux-audit ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: audit-userspace: auparse/lru.c sanity_check_queue() compile error with DEBUG 2017-12-19 19:49 ` Mor, Omri @ 2017-12-20 21:19 ` Steve Grubb 0 siblings, 0 replies; 4+ messages in thread From: Steve Grubb @ 2017-12-20 21:19 UTC (permalink / raw) To: Mor, Omri; +Cc: linux-audit@redhat.com [-- Attachment #1.1: Type: text/plain, Size: 681 bytes --] On Tuesday, December 19, 2017 2:49:08 PM EST Mor, Omri wrote: > >> sanity_check_queue() attempts to call msg(), which as far as I can tell > >> isn’t defined. It appears that this should be syslog() or audit_msg() > >> instead. > >> This causes compilation failure when DEBUG is defined. > > > > Thanks for reporting this. The function name is now fixed in git. > > On second look, I think it’s supposed to be syslog(), not audit_msg(). > The rest of the code in auparse/lru.c calls syslog(), Yes, I see that now. Normally syslog is wrapped so that messages can be switched between stderr and syslog depending on the needs. Its fixed again in git. -Steve [-- Attachment #1.2: Type: text/html, Size: 3218 bytes --] [-- Attachment #2: Type: text/plain, Size: 0 bytes --] ^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2017-12-20 21:19 UTC | newest] Thread overview: 4+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2017-12-18 1:19 audit-userspace: auparse/lru.c sanity_check_queue() compile error with DEBUG Mor, Omri 2017-12-18 17:34 ` Steve Grubb 2017-12-19 19:49 ` Mor, Omri 2017-12-20 21:19 ` Steve Grubb
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.