This is the mail archive of the
glibc-bugs@sourceware.org
mailing list for the glibc project.
[Bug libc/13763] bindresvport() function is multithread-unsafe
- From: "carlos_odonell at mentor dot com" <sourceware-bugzilla at sourceware dot org>
- To: glibc-bugs at sources dot redhat dot com
- Date: Mon, 19 Nov 2012 06:57:41 +0000
- Subject: [Bug libc/13763] bindresvport() function is multithread-unsafe
- Auto-submitted: auto-generated
- References: <bug-13763-131@http.sourceware.org/bugzilla/>
http://sourceware.org/bugzilla/show_bug.cgi?id=13763
Carlos O'Donell <carlos_odonell at mentor dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |RESOLVED
Resolution| |FIXED
Target Milestone|--- |2.17
--- Comment #4 from Carlos O'Donell <carlos_odonell at mentor dot com> 2012-11-19 06:57:41 UTC ---
commit f6da27e53695ad1cc0e2a9490358decbbfdff5e5
Author: Peng Haitao <penght@cn.fujitsu.com>
Date: Mon Nov 19 01:53:07 2012 -0500
bindresvport() uses two static variables port and startport which are not
protected. It is not safe when in multithread circumstance.
bindresvport() select a port number from the range 512 to 1023, when in
multithread circumstance, the port may be 1024. So the static variables
will be
protected.
Signed-off-by: Peng Haitao <penght@cn.fujitsu.com>
Reviewed-by: Carlos O'Donell <carlos@systemhalted.org>
---
2012-11-19 Peng Haitao <penght@cn.fujitsu.com>
[BZ #13763]
* sunrpc/bindrsvprt.c: Add lock to protect static variable.
--
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.