From stefan@fafoe.dyndns.org  Mon Oct 14 15:08:13 2002
Return-Path: <stefan@fafoe.dyndns.org>
Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125])
	by hub.freebsd.org (Postfix) with ESMTP id 8270D37B401
	for <FreeBSD-gnats-submit@freebsd.org>; Mon, 14 Oct 2002 15:08:13 -0700 (PDT)
Received: from fafoe.dyndns.org (chello212186121237.14.vie.surfer.at [212.186.121.237])
	by mx1.FreeBSD.org (Postfix) with ESMTP id D058443EAC
	for <FreeBSD-gnats-submit@freebsd.org>; Mon, 14 Oct 2002 15:08:12 -0700 (PDT)
	(envelope-from stefan@fafoe.dyndns.org)
Received: by frog.fafoe (Postfix, from userid 1001)
	id 866D02B0; Tue, 15 Oct 2002 00:08:11 +0200 (CEST)
Message-Id: <20021014220811.866D02B0@frog.fafoe>
Date: Tue, 15 Oct 2002 00:08:11 +0200 (CEST)
From: Stefan Farfeleder <stefan@frog.fafoe>
Reply-To: Stefan Farfeleder <stefan@frog.fafoe>
To: FreeBSD-gnats-submit@freebsd.org
Cc: Stefan Farfeleder <e0026813@stud3.tuwien.ac.at>
Subject: [PATCH] newsyslog getopt string contains erroneous "t:"
X-Send-Pr-Version: 3.113
X-GNATS-Notify:

>Number:         44066
>Category:       bin
>Synopsis:       [PATCH] newsyslog getopt string contains erroneous "t:"
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    maxim
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Mon Oct 14 15:10:01 PDT 2002
>Closed-Date:    Wed Oct 23 00:42:36 PDT 2002
>Last-Modified:  Wed Oct 23 00:42:36 PDT 2002
>Originator:     Stefan Farfeleder
>Release:        FreeBSD 4.7-STABLE i386
>Organization:
>Environment:
System: FreeBSD frog.fafoe 4.7-STABLE FreeBSD 4.7-STABLE #0: Thu Oct 10 18:20:30 CEST 2002 freebsd@frog.fafoe:/freebsd/stable/obj/freebsd/stable/src/sys/FROG i386


	
>Description:
The "t:" in the getopt string was an error in the original source imported from
NetBSD.  There it was fixed in revision 1.21.
	
>How-To-Repeat:
frog# newsyslog -t
newsyslog: option requires an argument -- t
usage: newsyslog [-Fnrv] [-f config-file] [-a directory]
frog# newsyslog -t foo
usage: newsyslog [-Fnrv] [-f config-file] [-a directory]

>Fix:
[This patch is against -current]


Index: newsyslog.c
===================================================================
RCS file: /home/ncvs/src/usr.sbin/newsyslog/newsyslog.c,v
retrieving revision 1.44
diff -u -r1.44 newsyslog.c
--- newsyslog.c	1 Jul 2002 13:18:52 -0000	1.44
+++ newsyslog.c	14 Oct 2002 21:40:52 -0000
@@ -230,7 +230,7 @@
 	if ((p = strchr(hostname, '.'))) {
 		*p = '\0';
 	}
-	while ((c = getopt(argc, argv, "nrvFf:a:t:")) != -1)
+	while ((c = getopt(argc, argv, "nrvFf:a:")) != -1)
 		switch (c) {
 		case 'n':
 			noaction++;
>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->patched 
State-Changed-By: maxim 
State-Changed-When: Wed Oct 16 07:20:49 PDT 2002 
State-Changed-Why:  
Fixed in rev. 1.45 src/usr.sbin/newsyslog/newsyslog.c in -current. Thanks! 


Responsible-Changed-From-To: freebsd-bugs->maxim 
Responsible-Changed-By: maxim 
Responsible-Changed-When: Wed Oct 16 07:20:49 PDT 2002 
Responsible-Changed-Why:  
I'll MFC the diff in one week. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=44066 
State-Changed-From-To: patched->closed 
State-Changed-By: maxim 
State-Changed-When: Wed Oct 23 00:41:16 PDT 2002 
State-Changed-Why:  
Fixed in rev. 1.45 and rev. 1.25.2.10 src/usr.sbin/newsyslog/newsyslog.c 
in -CURRENT and -STABLE. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=44066 
>Unformatted:
