Subject: CVS commit: src/lib/libc/gen
To: None <>
From: Christos Zoulas <>
List: source-changes
Date: 11/10/2004 23:59:06
Module Name:	src
Committed By:	christos
Date:		Wed Nov 10 23:59:06 UTC 2004

Modified Files:
	src/lib/libc/gen: getttyent.c

Log Message:
PR/28183: Brian Marcotte: Getty eats the last character of the last field.
As Brian reports the bug is in skip(). The logic on end of line is broken.

- fix the bug which can cause buf[-1] to be written.
- don't leave the line buffer allocated on end of file.
- use __func__ instead of hard-coding the function name.
- don't use needlessly global variables

To generate a diff of this commit:
cvs rdiff -r1.20 -r1.21 src/lib/libc/gen/getttyent.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.