public inbox for glibc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug network/19074] New: Data race in _res_hconf_reorder_addrs
@ 2015-10-06 12:17 fweimer at redhat dot com
  2015-10-14 14:50 ` [Bug network/19074] " cvs-commit at gcc dot gnu.org
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: fweimer at redhat dot com @ 2015-10-06 12:17 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=19074

            Bug ID: 19074
           Summary: Data race in _res_hconf_reorder_addrs
           Product: glibc
           Version: 2.23
            Status: NEW
          Severity: normal
          Priority: P2
         Component: network
          Assignee: fweimer at redhat dot com
          Reporter: fweimer at redhat dot com
  Target Milestone: ---
             Flags: security-

_res_hconf_reorder_addrs contains an instance of the incorrect double-checked
locking idiom:

  /* Number of interfaces.  */
  static int num_ifs = -1;
  /* We need to protect the dynamic buffer handling.  */
  __libc_lock_define_initialized (static, lock);
…
  if (num_ifs <= 0)
    {
…
      /* Get lock.  */
      __libc_lock_lock (lock);

      /* Recheck, somebody else might have done the work by now.  */
      if (num_ifs <= 0)
…
          num_ifs = new_num_ifs;
        }

      __libc_lock_unlock (lock);

num_ifs needs to be accessed with acquire loads and a release store.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
>From glibc-bugs-return-30041-listarch-glibc-bugs=sources.redhat.com@sourceware.org Tue Oct 06 12:17:48 2015
Return-Path: <glibc-bugs-return-30041-listarch-glibc-bugs=sources.redhat.com@sourceware.org>
Delivered-To: listarch-glibc-bugs@sources.redhat.com
Received: (qmail 51393 invoked by alias); 6 Oct 2015 12:17:48 -0000
Mailing-List: contact glibc-bugs-help@sourceware.org; run by ezmlm
Precedence: bulk
List-Id: <glibc-bugs.sourceware.org>
List-Subscribe: <mailto:glibc-bugs-subscribe@sourceware.org>
List-Post: <mailto:glibc-bugs@sourceware.org>
List-Help: <mailto:glibc-bugs-help@sourceware.org>, <http://sourceware.org/lists.html#faqs>
Sender: glibc-bugs-owner@sourceware.org
Delivered-To: mailing list glibc-bugs@sourceware.org
Received: (qmail 51358 invoked by uid 48); 6 Oct 2015 12:17:44 -0000
From: "fweimer at redhat dot com" <sourceware-bugzilla@sourceware.org>
To: glibc-bugs@sourceware.org
Subject: [Bug network/19074] Data race in _res_hconf_reorder_addrs
Date: Tue, 06 Oct 2015 12:17:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: glibc
X-Bugzilla-Component: network
X-Bugzilla-Version: 2.23
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: fweimer at redhat dot com
X-Bugzilla-Status: ASSIGNED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P2
X-Bugzilla-Assigned-To: fweimer at redhat dot com
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags: security-
X-Bugzilla-Changed-Fields: bug_status
Message-ID: <bug-19074-131-Q8I2W0ERX1@http.sourceware.org/bugzilla/>
In-Reply-To: <bug-19074-131@http.sourceware.org/bugzilla/>
References: <bug-19074-131@http.sourceware.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: 7bit
X-Bugzilla-URL: http://sourceware.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2015-10/txt/msg00078.txt.bz2
Content-length: 377

https://sourceware.org/bugzilla/show_bug.cgi?id\x19074

Florian Weimer <fweimer at redhat dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |ASSIGNED

--
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2015-10-29 17:11 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-10-06 12:17 [Bug network/19074] New: Data race in _res_hconf_reorder_addrs fweimer at redhat dot com
2015-10-14 14:50 ` [Bug network/19074] " cvs-commit at gcc dot gnu.org
2015-10-14 14:50 ` fweimer at redhat dot com
2015-10-29 17:11 ` jsm28 at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).