gstreamer/libs/gst/check/libcheck/strsignal.c
Anthony G. Basile c9da8b0e7f libcompat.h: strsignal() should be not be decleared const
POSIX standards requires strsignal() to return a pointer to a char,
not a const pointer to a char. [1]  On uClibc, and possibly other
libc's, that do not HAVE_DECL_STRSIGNAL, libcompat.h declares
const char *strsignal (int sig) which causes a type error.

[1] man 3 strsignal

https://bugzilla.gnome.org/show_bug.cgi?id=763567
2016-05-07 11:54:54 +01:00

10 lines
138 B
C

#include "libcompat.h"
char *
strsignal (int sig)
{
static char signame[40];
sprintf (signame, "SIG #%d", sig);
return signame;
}