diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2003-12-10 22:57:13 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2003-12-10 22:57:13 +0000 |
commit | f301ba466dfb185b024d95455d2755fff9a5b775 (patch) | |
tree | 85cbfd1f130dd156ec7cfc19386b853daef04a8a /libexec | |
parent | 1910523b38606e5702820cd90ddb7a38a7a1a833 (diff) |
spacing
Diffstat (limited to 'libexec')
-rw-r--r-- | libexec/ftpd/extern.h | 6 | ||||
-rw-r--r-- | libexec/ftpd/ftpcmd.y | 54 | ||||
-rw-r--r-- | libexec/ftpd/ftpd.c | 24 | ||||
-rw-r--r-- | libexec/ftpd/logutmp.c | 4 | ||||
-rw-r--r-- | libexec/ftpd/logwtmp.c | 6 | ||||
-rw-r--r-- | libexec/ftpd/popen.c | 6 |
6 files changed, 51 insertions, 49 deletions
diff --git a/libexec/ftpd/extern.h b/libexec/ftpd/extern.h index 4ea60241d8d..dcb9e044ba8 100644 --- a/libexec/ftpd/extern.h +++ b/libexec/ftpd/extern.h @@ -1,10 +1,10 @@ -/* $OpenBSD: extern.h,v 1.12 2003/07/07 03:18:11 deraadt Exp $ */ +/* $OpenBSD: extern.h,v 1.13 2003/12/10 22:57:12 deraadt Exp $ */ /* $NetBSD: extern.h,v 1.2 1995/04/11 02:44:49 cgd Exp $ */ /* * Copyright (C) 1997 and 1998 WIDE Project. * All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: @@ -16,7 +16,7 @@ * 3. Neither the name of the project nor the names of its contributors * may be used to endorse or promote products derived from this software * without specific prior written permission. - * + * * THIS SOFTWARE IS PROVIDED BY THE PROJECT AND CONTRIBUTORS ``AS IS'' AND * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE diff --git a/libexec/ftpd/ftpcmd.y b/libexec/ftpd/ftpcmd.y index 6a31c1f302b..1e67ce2b3df 100644 --- a/libexec/ftpd/ftpcmd.y +++ b/libexec/ftpd/ftpcmd.y @@ -1,4 +1,4 @@ -/* $OpenBSD: ftpcmd.y,v 1.42 2003/06/02 19:38:24 millert Exp $ */ +/* $OpenBSD: ftpcmd.y,v 1.43 2003/12/10 22:57:12 deraadt Exp $ */ /* $NetBSD: ftpcmd.y,v 1.7 1996/04/08 19:03:11 jtc Exp $ */ /* @@ -43,8 +43,8 @@ #if 0 static const char sccsid[] = "@(#)ftpcmd.y 8.3 (Berkeley) 4/6/94"; #else -static const char rcsid[] = - "$OpenBSD: ftpcmd.y,v 1.42 2003/06/02 19:38:24 millert Exp $"; +static const char rcsid[] = + "$OpenBSD: ftpcmd.y,v 1.43 2003/12/10 22:57:12 deraadt Exp $"; #endif #endif /* not lint */ @@ -169,7 +169,7 @@ cmd if ($2) { if ($4) { usedefault = 1; - reply(500, + reply(500, "Illegal PORT rejected (range errors)."); } else if (portcheck && ntohs(data_dest.su_sin.sin_port) < IPPORT_RESERVED) { @@ -282,7 +282,7 @@ cmd case TYPE_E: reply(504, "Type E not implemented."); break; - + case TYPE_I: reply(200, "Type set to I."); type = cmd_type; @@ -290,11 +290,11 @@ cmd case TYPE_L: if (cmd_bytesz == 8) { - reply(200, - "Type set to L (byte size 8)."); - type = cmd_type; + reply(200, + "Type set to L (byte size 8)."); + type = cmd_type; } else - reply(504, "Byte size must be 8."); + reply(504, "Byte size must be 8."); } } @@ -410,7 +410,7 @@ cmd free(fromname); fromname = NULL; } else { - reply(503, + reply(503, "Bad sequence of commands."); } } @@ -419,7 +419,7 @@ cmd } | ABOR check_login CRLF { - if ($2) + if ($2) reply(225, "ABOR command successful."); } | CWD check_login CRLF @@ -542,18 +542,19 @@ cmd | SITE SP check_login IDLE CRLF { if ($3) - reply(200, - "Current IDLE time limit is %d seconds; max %d", - timeout, maxtimeout); + reply(200, + "Current IDLE time limit is %d " + "seconds; max %d", + timeout, maxtimeout); } | SITE SP check_login IDLE SP NUMBER CRLF { if ($3) { if ($6 < 30 || $6 > maxtimeout) { - reply(501, - "Maximum IDLE time must be between " - "30 and %d seconds", - maxtimeout); + reply(501, + "Maximum IDLE time must be between " + "30 and %d seconds", + maxtimeout); } else { timeout = $6; (void) alarm((unsigned) timeout); @@ -648,7 +649,7 @@ rcmd { restart_point = (off_t) 0; if ($2 && $4) { - if (fromname) + if (fromname) free(fromname); fromname = renamefrom($4); if (fromname == NULL) @@ -661,13 +662,14 @@ rcmd | REST check_login SP byte_size CRLF { if ($2) { - if (fromname) { - free(fromname); - fromname = NULL; - } - restart_point = $4; /* XXX $4 is only "int" */ - reply(350, "Restarting at %qd. %s", restart_point, - "Send STORE or RETRIEVE to initiate transfer."); + if (fromname) { + free(fromname); + fromname = NULL; + } + restart_point = $4; /* XXX $4 is only "int" */ + reply(350, "Restarting at %qd. %s", + restart_point, + "Send STORE or RETRIEVE to initiate transfer."); } } ; diff --git a/libexec/ftpd/ftpd.c b/libexec/ftpd/ftpd.c index d673565692a..42f1e254790 100644 --- a/libexec/ftpd/ftpd.c +++ b/libexec/ftpd/ftpd.c @@ -1,10 +1,10 @@ -/* $OpenBSD: ftpd.c,v 1.151 2003/12/09 22:55:47 deraadt Exp $ */ +/* $OpenBSD: ftpd.c,v 1.152 2003/12/10 22:57:12 deraadt Exp $ */ /* $NetBSD: ftpd.c,v 1.15 1995/06/03 22:46:47 mycroft Exp $ */ /* * Copyright (C) 1997 and 1998 WIDE Project. * All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: @@ -16,7 +16,7 @@ * 3. Neither the name of the project nor the names of its contributors * may be used to endorse or promote products derived from this software * without specific prior written permission. - * + * * THIS SOFTWARE IS PROVIDED BY THE PROJECT AND CONTRIBUTORS ``AS IS'' AND * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE @@ -69,8 +69,8 @@ static const char copyright[] = #if 0 static const char sccsid[] = "@(#)ftpd.c 8.4 (Berkeley) 4/16/94"; #else -static const char rcsid[] = - "$OpenBSD: ftpd.c,v 1.151 2003/12/09 22:55:47 deraadt Exp $"; +static const char rcsid[] = + "$OpenBSD: ftpd.c,v 1.152 2003/12/10 22:57:12 deraadt Exp $"; #endif #endif /* not lint */ @@ -1363,7 +1363,7 @@ dataconn(char *name, off_t size, char *mode) file_size = size; byte_count = 0; if (size != (off_t) -1) { - (void) snprintf(sizebuf, sizeof(sizebuf), " (%qd bytes)", + (void) snprintf(sizebuf, sizeof(sizebuf), " (%qd bytes)", size); } else sizebuf[0] = '\0'; @@ -1410,7 +1410,7 @@ dataconn(char *name, off_t size, char *mode) return (NULL); } if (portcheck && memcmp(fa, ha, alen) != 0) { - perror_reply(435, "Can't build data connection"); + perror_reply(435, "Can't build data connection"); (void) close(pdata); (void) close(s); pdata = -1; @@ -1436,8 +1436,8 @@ dataconn(char *name, off_t size, char *mode) if (file == NULL) { char hbuf[MAXHOSTNAMELEN], pbuf[10]; - getnameinfo((struct sockaddr *)&data_source, - data_source.su_len, hbuf, sizeof(hbuf), pbuf, + getnameinfo((struct sockaddr *)&data_source, + data_source.su_len, hbuf, sizeof(hbuf), pbuf, sizeof(pbuf), NI_NUMERICHOST | NI_NUMERICSERV); reply(425, "Can't create data socket (%s,%s): %s.", hbuf, pbuf, strerror(errno)); @@ -2505,9 +2505,9 @@ protounsupp: /* * 522 Protocol not supported (proto,...) - * as we assume address family for control and data connections are the same, - * we do not return the list of address families we support - instead, we - * return the address family of the control connection. + * as we assume address family for control and data connections are the same, + * we do not return the list of address families we support - instead, we + * return the address family of the control connection. */ void epsv_protounsupp(const char *message) diff --git a/libexec/ftpd/logutmp.c b/libexec/ftpd/logutmp.c index 39f09cf3e6a..03629ac4d02 100644 --- a/libexec/ftpd/logutmp.c +++ b/libexec/ftpd/logutmp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: logutmp.c,v 1.7 2003/07/07 03:18:11 deraadt Exp $ */ +/* $OpenBSD: logutmp.c,v 1.8 2003/12/10 22:57:12 deraadt Exp $ */ /* * Portions Copyright (c) 1988, 1993 * The Regents of the University of California. All rights reserved. @@ -69,7 +69,7 @@ ftpd_login(struct utmp *ut) } if ((topslot < 0) || ((fd < 0) && (fd = open(_PATH_UTMP, O_RDWR|O_CREAT, 0644)) < 0)) - return; + return; /* * Now find a slot that's not in use... diff --git a/libexec/ftpd/logwtmp.c b/libexec/ftpd/logwtmp.c index 8fa97fd35d6..90e83932bbc 100644 --- a/libexec/ftpd/logwtmp.c +++ b/libexec/ftpd/logwtmp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: logwtmp.c,v 1.7 2003/06/11 14:24:46 deraadt Exp $ */ +/* $OpenBSD: logwtmp.c,v 1.8 2003/12/10 22:57:12 deraadt Exp $ */ /* $NetBSD: logwtmp.c,v 1.4 1995/04/11 02:44:58 cgd Exp $ */ /* @@ -35,8 +35,8 @@ #if 0 static const char sccsid[] = "@(#)logwtmp.c 8.1 (Berkeley) 6/4/93"; #else -static const char rcsid[] = - "$OpenBSD: logwtmp.c,v 1.7 2003/06/11 14:24:46 deraadt Exp $"; +static const char rcsid[] = + "$OpenBSD: logwtmp.c,v 1.8 2003/12/10 22:57:12 deraadt Exp $"; #endif #endif /* not lint */ diff --git a/libexec/ftpd/popen.c b/libexec/ftpd/popen.c index 38ab9b8a816..4b57d570a78 100644 --- a/libexec/ftpd/popen.c +++ b/libexec/ftpd/popen.c @@ -1,4 +1,4 @@ -/* $OpenBSD: popen.c,v 1.19 2003/06/11 14:24:46 deraadt Exp $ */ +/* $OpenBSD: popen.c,v 1.20 2003/12/10 22:57:12 deraadt Exp $ */ /* $NetBSD: popen.c,v 1.5 1995/04/11 02:45:00 cgd Exp $ */ /* @@ -38,8 +38,8 @@ #if 0 static const char sccsid[] = "@(#)popen.c 8.3 (Berkeley) 4/6/94"; #else -static const char rcsid[] = - "$OpenBSD: popen.c,v 1.19 2003/06/11 14:24:46 deraadt Exp $"; +static const char rcsid[] = + "$OpenBSD: popen.c,v 1.20 2003/12/10 22:57:12 deraadt Exp $"; #endif #endif /* not lint */ |