From f084cc9a342aa3d08054a5a930833b390a063bcd Mon Sep 17 00:00:00 2001 From: Herbert Xu Date: Sat, 29 Oct 2005 21:39:47 +1000 Subject: [SIGNAL] Added default implementation of strsignal klibc doesn't have strsignal but it does have sys_siglist. --- src/jobs.c | 1 + src/system.c | 14 ++++++++++++++ src/system.h | 4 ++++ 3 files changed, 19 insertions(+) (limited to 'src') diff --git a/src/jobs.c b/src/jobs.c index d5ea156..158d4e4 100644 --- a/src/jobs.c +++ b/src/jobs.c @@ -65,6 +65,7 @@ #include "memalloc.h" #include "error.h" #include "mystring.h" +#include "system.h" /* mode flags for set_curjob */ #define CUR_DELETE 2 diff --git a/src/system.c b/src/system.c index d375de0..d986efd 100644 --- a/src/system.c +++ b/src/system.c @@ -26,7 +26,9 @@ * SUCH DAMAGE. */ +#include #include +#include "output.h" #include "system.h" #ifndef HAVE_MEMPCPY @@ -53,6 +55,18 @@ char *strchrnul(const char *s, int c) } #endif +#ifndef HAVE_STRSIGNAL +char *strsignal(int sig) +{ + static char buf[19]; + + if ((unsigned)sig < NSIG && sys_siglist[sig]) + return (char *)sys_siglist[sig]; + fmtstr(buf, sizeof(buf), "Signal %d", sig); + return buf; +} +#endif + #ifndef HAVE_BSEARCH void *bsearch(const void *key, const void *base, size_t nmemb, size_t size, int (*cmp)(const void *, const void *)) diff --git a/src/system.h b/src/system.h index d686024..0842675 100644 --- a/src/system.h +++ b/src/system.h @@ -51,6 +51,10 @@ char *stpcpy(char *, const char *); char *strchrnul(const char *, int); #endif +#ifndef HAVE_STRSIGNAL +char *strsignal(int); +#endif + #ifndef HAVE_STRTOIMAX #define strtoimax strtoll #endif -- cgit 1.4.1 value='grep'>log msg
Commit message (Expand)Author
2019-11-18Document accept and exit behaviorJune McEnroe
2019-11-18Remove ISUPPORT draft referenceJune McEnroe
2019-11-18Document inadvertent echo bugJune McEnroe
2019-11-15Request NAMES on sync by defaultJune McEnroe
2019-11-14Add concept of passive clientsJune McEnroe
2019-11-14Save and load full struct timevalJune McEnroe
2019-11-14Use struct timeval for sub-second precisionJune McEnroe
2019-11-14Remove server-time filter TODOJune McEnroe
2019-11-14Tweak filter regexesJune McEnroe
2019-11-14Filter multi-prefixJune McEnroe
2019-11-14Replace filters with regex replacesJune McEnroe
2019-11-13Refactor filterUserhostInNamesJune McEnroe
2019-11-13Factor out wordcpy for filtersJune McEnroe
2019-11-11Revert "Test getopt_config"June McEnroe
2019-11-11Test getopt_configJune McEnroe
2019-11-11Add userhost-in-names to manualJune McEnroe
2019-11-11Skip initial NAMES parametersJune McEnroe
2019-11-11Filter userhost-in-namesJune McEnroe
2019-11-10Compare words without copying in filtersJune McEnroe
2019-11-10Separate tags from all targetJune McEnroe
2019-11-10Filter invite-notifyJune McEnroe
2019-11-10Add capsicum note to READMEJune McEnroe
2019-11-10Filter extended-joinJune McEnroe
2019-11-10Expand client configuration documentation and list capabilitiesJune McEnroe
2019-11-10Request all supported caps from serverJune McEnroe
2019-11-10Filter ACCOUNT, AWAY, CHGHOST for incapable clientsJune McEnroe
2019-11-10Rename listen to localJune McEnroe
2019-11-09Remove extended-join and invite-notifyJune McEnroe
2019-11-09Maintain stateCaps and offer them to clientsJune McEnroe
2019-11-09Parse capabilitiesJune McEnroe
2019-11-09Avoid the reserved _A names with BIT macroJune McEnroe
2019-11-09Define macro for bit flag enumsJune McEnroe
2019-11-08Check that password is hashedJune McEnroe
2019-11-08Avoid calling getopt_long again after it returns -1June McEnroe
2019-11-08Only change AWAY status for registered clientsJune McEnroe
2019-11-07Just write the example normallyJune McEnroe
2019-11-07Include path in readlinkat errorJune McEnroe
2019-11-07Call clientConsume before clientRecvJune McEnroe
2019-11-06Use -l:filename in Linux.mkJune McEnroe
2019-11-06Fix compat.h for #defined strlcpyJune McEnroe
2019-11-06Allow unsetting LIBRESSL_PREFIXJune McEnroe
2019-11-06Document calico service configurationJune McEnroe
2019-11-06Document SASL EXTERNAL configuration in more detailJune McEnroe
2019-11-06Document pounce service configurationJune McEnroe
2019-11-06Mention Darwin and GNU/Linux in READMEJune McEnroe
2019-11-06Assume LibreSSL from brew on DarwinJune McEnroe
2019-11-06Remove -DNO_EXPLICIT_BZERO from Darwin.mkJune McEnroe
2019-11-06Don't install rc scripts or dirs on LinuxJune McEnroe