From nobody@FreeBSD.org  Sun Jul  8 06:25:21 2007
Return-Path: <nobody@FreeBSD.org>
Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52])
	by hub.freebsd.org (Postfix) with ESMTP id A9FEC16A400
	for <freebsd-gnats-submit@FreeBSD.org>; Sun,  8 Jul 2007 06:25:21 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from www.freebsd.org (www.freebsd.org [69.147.83.33])
	by mx1.freebsd.org (Postfix) with ESMTP id 9733413C448
	for <freebsd-gnats-submit@FreeBSD.org>; Sun,  8 Jul 2007 06:25:21 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from www.freebsd.org (localhost [127.0.0.1])
	by www.freebsd.org (8.13.1/8.13.1) with ESMTP id l686PLBk013628
	for <freebsd-gnats-submit@FreeBSD.org>; Sun, 8 Jul 2007 06:25:21 GMT
	(envelope-from nobody@www.freebsd.org)
Received: (from nobody@localhost)
	by www.freebsd.org (8.13.1/8.13.1/Submit) id l686PLsv013627;
	Sun, 8 Jul 2007 06:25:21 GMT
	(envelope-from nobody)
Message-Id: <200707080625.l686PLsv013627@www.freebsd.org>
Date: Sun, 8 Jul 2007 06:25:21 GMT
From: Tim Daneliuk <tundra@tundraware.com>
To: freebsd-gnats-submit@FreeBSD.org
Subject: /etc/ttys not parsed properly if last line does not end with \n
X-Send-Pr-Version: www-3.0

>Number:         114398
>Category:       bin
>Synopsis:       init(8): /etc/ttys not parsed properly if last line does not end with \n
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    das
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sun Jul 08 06:30:07 GMT 2007
>Closed-Date:    Tue Jan 15 06:51:27 UTC 2008
>Last-Modified:  Tue Jan 15 07:00:02 UTC 2008
>Originator:     Tim Daneliuk
>Release:        6.2-STABLE
>Organization:
TundraWare Inc.
>Environment:
FreeBSD ozzie.tundraware.com 6.2-STABLE FreeBSD 6.2-STABLE #11: Sat Jul  7 12:38:43 CDT 2007     toor@ozzie.tundraware.com:/usr/obj/usr/src/sys/OZZIE  i386

>Description:
Added this to the end of /etc/ttys:

  ttyd0   "/usr/libexec/getty dial.115200" unknown on insecure

This was unrecognized when a 'kill -HUP 1' was subsequently done.
The problem turns out to occur only when the last line of the file
(the line above) is not newline terminated.  Adding the newline
made the problem go away.
>How-To-Repeat:

>Fix:


>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-bugs->das 
Responsible-Changed-By: das 
Responsible-Changed-When: Tue Jan 15 06:46:42 UTC 2008 
Responsible-Changed-Why:  
Over to me. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=114398 
State-Changed-From-To: open->closed 
State-Changed-By: das 
State-Changed-When: Tue Jan 15 06:50:52 UTC 2008 
State-Changed-Why:  
Fixed in src/lib/libc/gen/getttyent.c,v 1.17, thanks! 

http://www.freebsd.org/cgi/query-pr.cgi?pr=114398 

From: dfilter@FreeBSD.ORG (dfilter service)
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: bin/114398: commit references a PR
Date: Tue, 15 Jan 2008 06:50:59 +0000 (UTC)

 das         2008-01-15 06:50:50 UTC
 
   FreeBSD src repository
 
   Modified files:
     lib/libc/gen         getttyent.c 
   Log:
   In getttyent(3), if /etc/ttys doesn't end in a newline, don't
   freak out and keep trying to expand the buffer until realloc()
   fails.
   
   PR:     114398
   
   Revision  Changes    Path
   1.17      +1 -1      src/lib/libc/gen/getttyent.c
 _______________________________________________
 cvs-all@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/cvs-all
 To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
 
>Unformatted:
