misc/81732: A typo in tftpd.c
Denis Grudkin
denis41 at icape.nw.ru
Tue May 31 09:40:03 PDT 2005
>Number: 81732
>Category: misc
>Synopsis: A typo in tftpd.c
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: freebsd-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: sw-bug
>Submitter-Id: current-users
>Arrival-Date: Tue May 31 16:40:02 GMT 2005
>Closed-Date:
>Last-Modified:
>Originator: Denis Grudkin
>Release: FreeBSD 5.4-STABLE
>Organization:
ROKSON network
>Environment:
FreeBSD 5.4-STABLE i386
>Description:
tftpd server in FreeBSD 5.4-STABLE has an option -U to specify umask for newly created files. But then I tried to use this option I got segmentaion fault error. As I can see, the problem is in missed colon in getopt call in tftpd.c
Revision of my tftpd.c is 1.34
>How-To-Repeat:
Run tftpd server with -U option set.
>Fix:
Looks like all we need is to insert missing colon in tftpd.c
$ diff -u /usr/src/libexec/tftpd/tftpd.c ./tftpd.c
--- /usr/src/libexec/tftpd/tftpd.c Mon Aug 16 19:45:24 2004
+++ ./tftpd.c Tue May 31 20:07:42 2005
@@ -135,7 +135,7 @@
tzset(); /* syslog in localtime */
openlog("tftpd", LOG_PID | LOG_NDELAY, LOG_FTP);
- while ((ch = getopt(argc, argv, "cClns:u:Uw")) != -1) {
+ while ((ch = getopt(argc, argv, "cClns:u:U:w")) != -1) {
switch (ch) {
case 'c':
ipchroot = 1;
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-bugs
mailing list