[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: lib/39684 (RB_REMOVE trashes link to tree, when requested to remove object that isn't in tree)
The following reply was made to PR lib/39684; it has been noted by GNATS.
From: christos%zoulas.com@localhost (Christos Zoulas)
To: gnats-bugs%NetBSD.org@localhost, lib-bug-people%netbsd.org@localhost,
Subject: Re: lib/39684 (RB_REMOVE trashes link to tree, when requested to
remove object that isn't in tree)
Date: Tue, 7 Oct 2008 14:13:58 -0400
On Oct 7, 11:50am, cube%cubidou.net@localhost (Quentin Garnier) wrote:
-- Subject: Re: lib/39684 (RB_REMOVE trashes link to tree, when requested to
| You know, the fact that you're the one letting your code logic do
| something that it should not do puts you in a very bad position to make
| such comments. If code of yours runs into any of the devices you list,
| could you tell us brands and exact models? I feel kind of worried.
Well, this is really not productive. I think that the submitter here
has a point. The manual page states:
Accordingly, RB_REMOVE() and SPLAY_REMOVE() return the pointer to the
removed element, otherwise they return NULL to indicate an error.
Looking at the red-black code this is a lie. It never returns NULL and it
should really either:
1. not trash the tree or
2. at least document that it will trash the tree
Main Index |
Thread Index |