Never call syslog in __libc_message.

This commit is contained in:
Roland McGrath 2013-03-28 10:38:37 -07:00
parent b0f1246ab4
commit 356b348023
2 changed files with 5 additions and 9 deletions

View File

@ -1,3 +1,8 @@
2013-03-28 Roland McGrath <roland@hack.frob.com>
* sysdeps/posix/libc_fatal.c: Don't include <sys/syslog.h>.
(__libc_message): Never call vsyslog.
2013-03-28 Alan Modra <amodra@gmail.com> 2013-03-28 Alan Modra <amodra@gmail.com>
* sysdeps/powerpc/powerpc32/start.S (cfi_startproc, cfi_endproc): * sysdeps/powerpc/powerpc32/start.S (cfi_startproc, cfi_endproc):

View File

@ -29,7 +29,6 @@
#include <sysdep.h> #include <sysdep.h>
#include <unistd.h> #include <unistd.h>
#include <sys/mman.h> #include <sys/mman.h>
#include <sys/syslog.h>
#include <sys/uio.h> #include <sys/uio.h>
#include <not-cancel.h> #include <not-cancel.h>
@ -68,11 +67,9 @@ void
__libc_message (int do_abort, const char *fmt, ...) __libc_message (int do_abort, const char *fmt, ...)
{ {
va_list ap; va_list ap;
va_list ap_copy;
int fd = -1; int fd = -1;
va_start (ap, fmt); va_start (ap, fmt);
va_copy (ap_copy, ap);
#ifdef FATAL_PREPARE #ifdef FATAL_PREPARE
FATAL_PREPARE; FATAL_PREPARE;
@ -170,12 +167,6 @@ __libc_message (int do_abort, const char *fmt, ...)
va_end (ap); va_end (ap);
/* If we had no success writing the message, use syslog. */
if (! written)
vsyslog (LOG_ERR, fmt, ap_copy);
va_end (ap_copy);
if (do_abort) if (do_abort)
{ {
BEFORE_ABORT (do_abort, written, fd); BEFORE_ABORT (do_abort, written, fd);