提交 adb7093c 编写于 作者: R Rich Felker

fix missing prototypes/wrong signature for psiginfo, psignal

上级 1f5ff26c
...@@ -87,6 +87,9 @@ int sigqueue(pid_t, int, const union sigval); ...@@ -87,6 +87,9 @@ int sigqueue(pid_t, int, const union sigval);
int pthread_sigmask(int, const sigset_t *, sigset_t *); int pthread_sigmask(int, const sigset_t *, sigset_t *);
int pthread_kill(pthread_t, int); int pthread_kill(pthread_t, int);
void psiginfo(const siginfo_t *, const char *);
void psignal(int, const char *);
#endif #endif
#if defined(_XOPEN_SOURCE) || defined(_GNU_SOURCE) #if defined(_XOPEN_SOURCE) || defined(_GNU_SOURCE)
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
#include <string.h> #include <string.h>
#include <signal.h> #include <signal.h>
void psiginfo(siginfo_t *si, const char *msg) void psiginfo(const siginfo_t *si, const char *msg)
{ {
char *s = strsignal(si->si_signo); char *s = strsignal(si->si_signo);
if (msg) fprintf(stderr, "%s: %s\n", msg, s); if (msg) fprintf(stderr, "%s: %s\n", msg, s);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册