Adjust strsignal to POSIX 200x prototype.

2008-06-19  Eric Blake  <ebb9@byu.net>

	Adjust strsignal to POSIX 200x prototype.
	* strsignal.c (strsignal): Remove const.

From-SVN: r136949
This commit is contained in:
Eric Blake 2008-06-19 15:08:53 +00:00
parent 09a46078e1
commit 6819ba36b3
2 changed files with 26 additions and 19 deletions

View File

@ -1,3 +1,8 @@
2008-06-19 Eric Blake <ebb9@byu.net>
Adjust strsignal to POSIX 200x prototype.
* strsignal.c (strsignal): Remove const.
2008-06-17 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
* configure: Regenerate.
@ -252,7 +257,7 @@
* testsuite/Makefile.in: Add dummy install-pdf target.
2007-03-01 Peter Breitenlohner <peb@mppmu.mpg.de>
Eric Botcazou <ebotcazou@libertysurf.fr>
Eric Botcazou <ebotcazou@libertysurf.fr>
PR other/16513
* Makefile.in: Install library under $(MULTIOSDIR), not $(MULTISUBDIR).
@ -362,7 +367,7 @@
the end of the string.
2006-11-30 Andrew Stubbs <andrew.stubbs@st.com>
J"orn Rennecke <joern.rennecke@st.com>
J"orn Rennecke <joern.rennecke@st.com>
PR driver/29931
* make-relative-prefix.c (make_relative_prefix_1): New function,

View File

@ -404,10 +404,10 @@ call to @code{strsignal}.
#ifndef HAVE_STRSIGNAL
const char *
char *
strsignal (int signo)
{
const char *msg;
char *msg;
static char buf[32];
#ifndef HAVE_SYS_SIGLIST
@ -428,12 +428,14 @@ strsignal (int signo)
{
/* In range, but no sys_siglist or no entry at this index. */
sprintf (buf, "Signal %d", signo);
msg = (const char *) buf;
msg = buf;
}
else
{
/* In range, and a valid message. Just return the message. */
msg = (const char *) sys_siglist[signo];
/* In range, and a valid message. Just return the message. We
can safely cast away const, since POSIX says the user must
not modify the result. */
msg = (char *) sys_siglist[signo];
}
return (msg);