This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH Fix incorrect double-checked locking related to _res_hconf.initialized. [BZ #20477]
- From: Andreas Schwab <schwab at suse dot de>
- To: Florian Weimer <fweimer at redhat dot com>
- Cc: Torvald Riegel <triegel at redhat dot com>, GLIBC Devel <libc-alpha at sourceware dot org>
- Date: Thu, 18 Aug 2016 09:05:09 +0200
- Subject: Re: [PATCH Fix incorrect double-checked locking related to _res_hconf.initialized. [BZ #20477]
- Authentication-results: sourceware.org; auth=none
- References: <1471436135.14544.96.camel@localhost.localdomain> <mvm7fbfphxf.fsf@hawking.suse.de> <34c36d06-d419-a3f3-daca-9a1be66146a8@redhat.com>
On Aug 17 2016, Florian Weimer <fweimer@redhat.com> wrote:
> On 08/17/2016 04:51 PM, Andreas Schwab wrote:
>> On Aug 17 2016, Torvald Riegel <triegel@redhat.com> wrote:
>>
>>> diff --git a/resolv/res_hconf.h b/resolv/res_hconf.h
>>> index b97734d..a3d23f3 100644
>>> --- a/resolv/res_hconf.h
>>> +++ b/resolv/res_hconf.h
>>> @@ -25,6 +25,15 @@
>>>
>>> struct hconf
>>> {
>>> + /* We keep the INITIALIZED member only for backwards compatibility. New
>>> + code should just call _res_hconf_init unconditionally. For this field
>>> + to be used safely, users must ensure that either (1) a call to
>>> + _res_hconf_init happens-before any load from INITIALIZED, or (2) an
>> ^
>>> + assignment of zero to INITIALIZED happens-before any load from it, and
>> ^
>>
>> Those hyphens look wrong.
>
> “happens-before” is third-person singular of the verb
> “happen-before”. It's a technical term widely used while discussing memory
> models.
But writing it without hyphen is standard English and doesn't require
special knowledge.
Andreas.
--
Andreas Schwab, SUSE Labs, schwab@suse.de
GPG Key fingerprint = 0196 BAD8 1CE9 1970 F4BE 1748 E4D4 88E3 0EEA B9D7
"And now for something completely different."