From: Ken Raeburn Date: Tue, 21 Sep 1999 22:56:49 +0000 (+0000) Subject: Don't fclose(NULL). Don't declare string functions that are macros X-Git-Tag: krb5-1.2-beta1~228 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=0265426b5d113a7d7927a7ed82cfcdb9125b34c6;p=krb5.git Don't fclose(NULL). Don't declare string functions that are macros git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@11836 dc483132-0cff-0310-8789-dd5450dbe970 --- diff --git a/src/appl/gssftp/ftp/ChangeLog b/src/appl/gssftp/ftp/ChangeLog index 893c318d5..64a6890d5 100644 --- a/src/appl/gssftp/ftp/ChangeLog +++ b/src/appl/gssftp/ftp/ChangeLog @@ -1,3 +1,8 @@ +1999-09-21 Ken Raeburn + + * ftp.c (getreply): Don't declare strpbrk or strstr functions if + they're defined as macros. + 1999-08-27 Tom Yu * ftp.c: Diable krb5-mech2 for now. diff --git a/src/appl/gssftp/ftp/ftp.c b/src/appl/gssftp/ftp/ftp.c index bccd2facc..24049eabe 100644 --- a/src/appl/gssftp/ftp/ftp.c +++ b/src/appl/gssftp/ftp/ftp.c @@ -541,7 +541,12 @@ getreply(expecteof) sigtype cmdabort(); char ibuf[FTP_BUFSIZ], obuf[FTP_BUFSIZ]; int safe = 0; - extern char *strpbrk(), *strstr(); +#ifndef strpbrk + extern char *strpbrk(); +#endif +#ifndef strstr + extern char *strstr(); +#endif ibuf[0] = '\0'; if (reply_parse) reply_ptr = reply_buf; diff --git a/src/appl/gssftp/ftpd/ChangeLog b/src/appl/gssftp/ftpd/ChangeLog index c84e77028..3d5aa408e 100644 --- a/src/appl/gssftp/ftpd/ChangeLog +++ b/src/appl/gssftp/ftpd/ChangeLog @@ -1,3 +1,10 @@ +1999-09-21 Ken Raeburn + + * ftpd.c (checkuser): Only call fclose on file handle if it's not + NULL. + (send_file_list): Don't declare strpbrk function if it's defined + as a macro. + Thu Mar 25 23:13:56 1999 Tom Yu * ftpd.c (login): Check that the luid is not the uid we want to diff --git a/src/appl/gssftp/ftpd/ftpd.c b/src/appl/gssftp/ftpd/ftpd.c index d4987affc..52be05fb6 100644 --- a/src/appl/gssftp/ftpd/ftpd.c +++ b/src/appl/gssftp/ftpd/ftpd.c @@ -840,8 +840,8 @@ checkuser(name) } } } + (void) fclose(fd); } - (void) fclose(fd); return (0); } @@ -2018,7 +2018,9 @@ void myoob() { char *cp, *cs; +#ifndef strpbrk extern char *strpbrk(); +#endif /* only process if transfer occurring */ if (!transflag) @@ -2486,7 +2488,9 @@ send_file_list(whichfiles) FILE *dout = NULL; register char **dirlist, *dirname; int simple = 0; +#ifndef strpbrk char *strpbrk(); +#endif int ret = 0; if (strpbrk(whichfiles, "~{[*?") != NULL) {