diff options
author | Bernhard Reutner-Fischer <rep.dot.nop@gmail.com> | 2008-09-29 13:04:10 +0000 |
---|---|---|
committer | Bernhard Reutner-Fischer <rep.dot.nop@gmail.com> | 2008-09-29 13:04:10 +0000 |
commit | 630de1ac9d7122f0757d7a75ec1f13b5fa320d8e (patch) | |
tree | b1b54ded59ac54412bc4fb5e9f3734f03d27794b | |
parent | 9794acc88e9e0b352970c7c50ddbd6786ff59734 (diff) |
- honour UCLIBC_HAS_SYSLOG
-rw-r--r-- | libc/sysdeps/linux/common/ssp.c | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/libc/sysdeps/linux/common/ssp.c b/libc/sysdeps/linux/common/ssp.c index d8088ef60..1563700d5 100644 --- a/libc/sysdeps/linux/common/ssp.c +++ b/libc/sysdeps/linux/common/ssp.c @@ -29,18 +29,19 @@ #include <string.h> #include <unistd.h> #include <signal.h> +#if defined __UCLIBC_HAS_SYSLOG__ #include <sys/syslog.h> -/* Experimentally off - libc_hidden_proto(memset) */ -/* Experimentally off - libc_hidden_proto(strlen) */ +libc_hidden_proto(openlog) +libc_hidden_proto(syslog) +libc_hidden_proto(closelog) +#endif + libc_hidden_proto(sigaction) libc_hidden_proto(sigfillset) libc_hidden_proto(sigdelset) libc_hidden_proto(sigprocmask) libc_hidden_proto(write) -libc_hidden_proto(openlog) -libc_hidden_proto(syslog) -libc_hidden_proto(closelog) libc_hidden_proto(kill) libc_hidden_proto(getpid) libc_hidden_proto(_exit) @@ -69,9 +70,11 @@ static void ssp_write(int fd, const char *msg1, const char *msg2, const char *ms write(fd, msg2, strlen(msg2)); write(fd, msg3, strlen(msg3)); write(fd, "()\n", 3); +#if defined __UCLIBC_HAS_SYSLOG__ openlog("ssp", LOG_CONS | LOG_PID, LOG_USER); syslog(LOG_INFO, "%s%s%s()", msg1, msg2, msg3); closelog(); +#endif } static attribute_noreturn void terminate(void) |