This is the mail archive of the
glibc-bugs@sourceware.org
mailing list for the glibc project.
[Bug libc/9823] New: Error in psignal(int sig, const char * s) if s is an empty string
- From: "khoroshilov at linuxtesting dot org" <sourceware-bugzilla at sourceware dot org>
- To: glibc-bugs at sources dot redhat dot com
- Date: 6 Feb 2009 15:13:44 -0000
- Subject: [Bug libc/9823] New: Error in psignal(int sig, const char * s) if s is an empty string
- Reply-to: sourceware-bugzilla at sourceware dot org
/* Print out on stderr a line consisting of the test in S, a colon, a space,
a message describing the meaning of the signal number SIG and a newline.
If S is NULL or "", the colon and space are omitted. */
void
psignal (int sig, const char *s)
{
const char *colon, *desc;
- if (s == NULL || s == '\0')
+ if (s == NULL || *s == '\0')
s = colon = "";
else
colon = ": ";
There is a misprint in the code above (libc/stdio-common/psignal.c).
--
Summary: Error in psignal(int sig, const char * s) if s is an
empty string
Product: glibc
Version: 2.8
Status: NEW
Severity: normal
Priority: P2
Component: libc
AssignedTo: drepper at redhat dot com
ReportedBy: khoroshilov at linuxtesting dot org
CC: glibc-bugs at sources dot redhat dot com
http://sourceware.org/bugzilla/show_bug.cgi?id=9823
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.