From 31db19f8da99bc32483644d0fa3a9eb8723a573c Mon Sep 17 00:00:00 2001 From: Brendan Shanks Date: Tue, 31 Jul 2018 23:04:05 -0700 Subject: [PATCH] Remove strsignal(), only used by lsh --- macssh/source/ssh/ssh2.c | 44 ---------------------------------------- macssh/source/ssh/ssh2.h | 1 - 2 files changed, 45 deletions(-) diff --git a/macssh/source/ssh/ssh2.c b/macssh/source/ssh/ssh2.c index abb0a81..8a0506b 100755 --- a/macssh/source/ssh/ssh2.c +++ b/macssh/source/ssh/ssh2.c @@ -318,50 +318,6 @@ char * __strerror( int errnum, char *str ) return str; } -/* - * strsignal - */ - -#define __max_sigstr 64 - -char * strsignal( int signo ) -{ - static char sigstr[__max_sigstr]; - - switch (signo) - { - case SIGHUP: strcpy(sigstr, "SIGHUP, hangup"); break; - case SIGINT: strcpy(sigstr, "SIGINT, interrupt"); break; - case SIGQUIT: strcpy(sigstr, "SIGQUIT, quit"); break; - case SIGILL: strcpy(sigstr, "SIGILL, illegal instruction"); break; - case SIGABRT: strcpy(sigstr, "SIGABRT, abort"); break; - case SIGFPE: strcpy(sigstr, "SIGFPE, floating point exception"); break; - case SIGKILL: strcpy(sigstr, "SIGKILL, kill"); break; - case SIGSEGV: strcpy(sigstr, "SIGSEGV, segmentation violation"); break; - case SIGPIPE: strcpy(sigstr, "SIGPIPE, write on a pipe with no one to read it"); break; - case SIGALRM: strcpy(sigstr, "SIGALRM, alarm clock"); break; - case SIGTERM: strcpy(sigstr, "SIGTERM, software termination signal from kill"); break; -#ifndef _POSIX_SOURCE - case SIGURG: strcpy(sigstr, "SIGURG, urgent condition on IO channel"); break; -#endif - case SIGSTOP: strcpy(sigstr, "SIGSTOP, sendable stop signal not from tty"); break; - case SIGTSTP: strcpy(sigstr, "SIGSTOP, stop signal from tty"); break; - case SIGCONT: strcpy(sigstr, "SIGCONT, continue a stopped process"); break; - case SIGCHLD: strcpy(sigstr, "SIGCHLD"); break; - case SIGTTIN: strcpy(sigstr, "SIGTTIN"); break; - case SIGTTOU: strcpy(sigstr, "SIGTTOU"); break; -#ifndef _POSIX_SOURCE - case SIGIO: strcpy(sigstr, "SIGIO"); break; - case SIGPROF: strcpy(sigstr, "SIGPROF"); break; - case SIGWINCH: strcpy(sigstr, "SIGWINCH"); break; -#endif - case SIGUSR1: strcpy(sigstr, "SIGUSR1, user defined signal 1"); break; - case SIGUSR2: strcpy(sigstr, "SIGUSR2, user defined signal 2"); break; - default: sprintf(sigstr, "unknown signal no %d", signo); break; - } - return sigstr; -} - /* * getexitbuf */ diff --git a/macssh/source/ssh/ssh2.h b/macssh/source/ssh/ssh2.h index 15ca2ef..bb503d4 100755 --- a/macssh/source/ssh/ssh2.h +++ b/macssh/source/ssh/ssh2.h @@ -21,7 +21,6 @@ #define exit macosexit #define abort macosabort -extern char *strsignal(int signo); /*******/