Alleged bug in resolver code

Mark Kettenis kettenis@wins.uva.nl
Sat Jul 15 06:02:00 GMT 2000


   Date: Fri, 14 Jul 2000 20:46:40 -0700
   From: "H . J . Lu" <hjl@lucon.org>

   On Sat, Jul 15, 2000 at 03:12:49AM +0200, Mark Kettenis wrote:
   >    Date: Fri, 14 Jul 2000 17:57:17 -0700
   >    From: "H . J . Lu" <hjl@lucon.org>
   > 
   >    I don't like RedHat bug report either :-). I think people from Red Hat
   >    are on this mailing list. In any case, I don't have any problems to
   >    back out those 2 patches as long as you send me your patch on pump.
   > 
   > Replacing
   > 
   >   res_close ();
   > 
   > with
   > 
   >   if (_res.options & RES_INIT)
   >     res_close ();
   > 

   How about this patch instead? If res_nclose is not supposed to be
   called without initialization, this patch shouldn't break anything.


   H.J.
   --
   2000-07-14  H.J. Lu  <hjl@gnu.org>

	   * resolv/res_send.c (res_nclose): Return if not initialized.

I'd rather not do *that*.  The res_nclose() function is part of the
new thread-safe BIND-8 interfaces.  Those interfaces never call
res_ninit() themselves (e.g. you always have to pass them an initialize
resolver state).  Since these interfaces are new in glibc 2.2 there
are no backwards compatibility issues, and I think we should 

I've got less problems with applying a patch similar to yours to
res_close(), and I'll add that stuff if others on libc-hacker agree
that that's a good idea.  However, I still think it's the broken
programs that should be fixed.

Mark


More information about the Libc-hacker mailing list