This is the mail archive of the
glibc-bugs@sourceware.org
mailing list for the glibc project.
[Bug libc/1963] argument p not checked in io/fts.c:fts_load()
- From: "heiko dot nardmann at secunet dot com" <sourceware-bugzilla at sourceware dot org>
- To: glibc-bugs at sources dot redhat dot com
- Date: 2 Dec 2005 07:41:28 -0000
- Subject: [Bug libc/1963] argument p not checked in io/fts.c:fts_load()
- References: <20051201163208.1963.heiko.nardmann@secunet.com>
- Reply-to: sourceware-bugzilla at sourceware dot org
------- Additional Comments From heiko dot nardmann at secunet dot com 2005-12-02 07:41 -------
(In reply to comment #9)
> Undefined behaviour. NULL is not a valid stream.
What does this have to do with
"It means that p can never be NULL. Likewise for sp."
?
Where - besides the man page - is the behaviour of the fts_*() functions
defined? So that I can lookup the specification for it to review my patch ...
According to the man page e.g. for fts_set():
"The fts_set() function returns 0 on success, and -1 if an error occurs."
So a NULL pointer for an argument is IMHO a situation where an error has
occurred.
"In addition, fts_children(), fts_open() and fts_set() may fail and set errno
as follows:
[EINVAL] The options were invalid."
I also have stated:
"In function fts_set() the value 1 is returned in error case despite the fact
that the man page says '-1'. What is correct here?"
You did not give a comment for this one. Just putting this bug into state
"resolved invalid" - isn't it a bit too simple?
--
What |Removed |Added
----------------------------------------------------------------------------
Status|RESOLVED |REOPENED
Resolution|INVALID |
http://sourceware.org/bugzilla/show_bug.cgi?id=1963
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.