This is the mail archive of the
mailing list for the glibc project.
Re: [PATCH] hesiod_end: Do not call res_nclose(&_res) [BZ #19573]
- From: Anders Kaseorg <andersk at mit dot edu>
- To: Florian Weimer <fw at deneb dot enyo dot de>
- Cc: libc-alpha at sourceware dot org
- Date: Sat, 23 Apr 2016 14:37:15 -0400 (EDT)
- Subject: Re: [PATCH] hesiod_end: Do not call res_nclose(&_res) [BZ #19573]
- Authentication-results: sourceware.org; auth=none
- References: <alpine dot DEB dot 2 dot 10 dot 1604221400580 dot 60537 at buzzword-bingo dot mit dot edu> <87eg9wjynn dot fsf at mid dot deneb dot enyo dot de>
Thanks for the review!
On Sat, 23 Apr 2016, Florian Weimer wrote:
> Please use GNU style (braces on separate lines, two-space
hesiod/hesiod.c is not in GNU style; I preserved its existing style as per
> This is one way to fix this bug. Its correctness depends on whether we
> export in any way the hesiod functionality. I thought we did, but
> libhesiod is actually a separate thing, and checking with eu-readelf, I
> don't see any exports of the helper functions.
> If there are no external users of the callback mechanism, we do not have
> to worry about the behavioral change.
> I would welcome a quick double-check on this aspect.
I agree: this file is only used in nss_hesiod, whose only exported symbols
are the NSS interface.
Also, the test I used is the same as what __hesiod_res_set already uses
before calling res_nclose. This may not be strong evidence by itself,
because it happens that __hesiod_res_set is never called in a way that
satisfies this test, but at least itâs consistent.