All signal handlers return RETSIGTYPE.

git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@712 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
Assar Westerlund
1996-09-03 18:04:46 +00:00
parent 3467387cd6
commit a95bae9e0a
8 changed files with 36 additions and 34 deletions

View File

@@ -403,6 +403,27 @@ usage:
argv[1] != oldargv1 || argv[2] != oldargv2);
}
/* ARGSUSED */
static RETSIGTYPE
mabort(int signo)
{
int ointer;
printf("\n");
(void) fflush(stdout);
if (mflag && fromatty) {
ointer = interactive;
interactive = 1;
if (confirm("Continue with", mname)) {
interactive = ointer;
longjmp(jabort,0);
}
interactive = ointer;
}
mflag = 0;
longjmp(jabort,0);
}
/*
* Send multiple files.
*/
@@ -410,7 +431,7 @@ void
mput(int argc, char **argv)
{
int i;
sighand oldintr;
RETSIGTYPE (*oldintr)();
int ointer;
char *tp;
@@ -644,27 +665,6 @@ usage:
return (0);
}
/* ARGSUSED */
void
mabort(int signo)
{
int ointer;
printf("\n");
(void) fflush(stdout);
if (mflag && fromatty) {
ointer = interactive;
interactive = 1;
if (confirm("Continue with", mname)) {
interactive = ointer;
longjmp(jabort,0);
}
interactive = ointer;
}
mflag = 0;
longjmp(jabort,0);
}
/*
* Get multiple files.
*/
@@ -1177,7 +1177,7 @@ void
shell(int argc, char **argv)
{
pid_t pid;
sighand old1, old2;
RETSIGTYPE (*old1)(), (*old2)();
char shellnam[40], *shell, *namep;
int status;
@@ -1548,7 +1548,7 @@ account(int argc, char **argv)
jmp_buf abortprox;
void
static RETSIGTYPE
proxabort(int sig)
{
@@ -1569,7 +1569,7 @@ void
doproxy(int argc, char **argv)
{
struct cmd *c;
sighand oldintr;
RETSIGTYPE (*oldintr)();
if (argc < 2 && !another(&argc, &argv, "command")) {
printf("usage: %s command\n", argv[0]);

View File

@@ -90,9 +90,8 @@ int initconn __P((void));
void intr __P((int));
void lcd __P((int, char **));
int login __P((char *));
void lostpeer __P((int));
RETSIGTYPE lostpeer __P((int));
void ls __P((int, char **));
void mabort __P((int));
void macdef __P((int, char **));
void makeargv __P((void));
void makedir __P((int, char **));
@@ -103,7 +102,6 @@ void modtime __P((int, char **));
void mput __P((int, char **));
char *onoff __P((int));
void newer __P((int, char **));
void proxabort __P((int));
void proxtrans __P((char *, char *, char *));
void psabort __P((int));
void pswitch __P((int));

View File

@@ -520,7 +520,7 @@ empty(fd_set *mask, int sec)
jmp_buf sendabort;
void
static RETSIGTYPE
abortsend(int sig)
{
@@ -582,9 +582,9 @@ sendrequest(char *cmd, char *local, char *remote, int printnames)
struct stat st;
struct timeval start, stop;
int c, d;
FILE *fin, *dout = 0, *popen(const char *, const char *);
FILE *fin, *dout = 0;
int (*closefunc) __P((FILE *));
sighand oldintr, oldintp;
RETSIGTYPE (*oldintr)(), (*oldintp)();
long bytes = 0, hashbytes = HASHBYTES;
char *lmode;

View File

@@ -138,7 +138,7 @@ intr(int sig)
longjmp(toplevel, 1);
}
void
RETSIGTYPE
lostpeer(int sig)
{
@@ -166,6 +166,7 @@ lostpeer(int sig)
}
proxflag = 0;
pswitch(0);
SIGRETURN(0);
}
/*

View File

@@ -1004,7 +1004,7 @@ getline(char *s, int n)
return (s);
}
static void
static RETSIGTYPE
toolong(int signo)
{
@@ -1015,6 +1015,7 @@ toolong(int signo)
syslog(LOG_INFO, "User %s timed out after %d seconds",
(pw ? pw -> pw_name : "unknown"), ftpd_timeout);
dologout(1);
SIGRETURN(0);
}
static int

View File

@@ -82,6 +82,7 @@ childhandler (int sig)
pid = waitpid (-1, &status, WNOHANG|WUNTRACED);
} while(pid > 0);
signal (SIGCHLD, childhandler);
SIGRETURN(0);
}
/*

View File

@@ -22,6 +22,7 @@ catchSIGHUP(int sig)
/* This should not be a problem on BSD systems */
signal(SIGHUP, catchSIGHUP);
signal(SIGPIPE, catchSIGHUP);
SIGRETURN(0);
}
int pop_timeout = POP_TIMEOUT;

View File

@@ -515,7 +515,7 @@ static jmp_buf catch_SIGSYS;
#ifdef SIGSYS
static void
static RETSIGTYPE
SIGSYS_handler(int sig)
{
errno = 0;