mirror of
https://gitlab.com/sortix/sortix.git
synced 2023-02-13 20:55:38 -05:00
Fix format nonliteral in psignal(3).
This commit is contained in:
parent
91087d9199
commit
09084cf12d
1 changed files with 6 additions and 6 deletions
|
@ -1,6 +1,6 @@
|
|||
/*******************************************************************************
|
||||
|
||||
Copyright(C) Jonas 'Sortie' Termansen 2013.
|
||||
Copyright(C) Jonas 'Sortie' Termansen 2013, 2015.
|
||||
|
||||
This file is part of the Sortix C Library.
|
||||
|
||||
|
@ -28,9 +28,9 @@
|
|||
|
||||
extern "C" void psignal(int signum, const char* message)
|
||||
{
|
||||
flockfile(stderr);
|
||||
if ( message && message[0] )
|
||||
fprintf_unlocked(stderr, "%s: ", message);
|
||||
fprintf_unlocked(stderr, strsignal(signum));
|
||||
funlockfile(stderr);
|
||||
const char* signumstr = strsignal(signum);
|
||||
if ( message )
|
||||
fprintf(stderr, "%s: %s\n", message, signumstr);
|
||||
else
|
||||
fprintf(stderr, "%s\n", signumstr);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue