This is the mail archive of the
glibc-bugs@sourceware.org
mailing list for the glibc project.
[Bug libc/9890] New: clntraw_create and svcraw_create do not communicate
- From: "yair dot lenga at citi dot com" <sourceware-bugzilla at sourceware dot org>
- To: glibc-bugs at sources dot redhat dot com
- Date: 24 Feb 2009 12:34:53 -0000
- Subject: [Bug libc/9890] New: clntraw_create and svcraw_create do not communicate
- Reply-to: sourceware-bugzilla at sourceware dot org
The clntraw_create and svcraw_create functions are part of the SUNRPC package.
They are being used to implement in-process RPC - where a program can send an
RPC to itself. I'm using this function to to provide XML/HTTP interface for old
legacy program.
See the attached small program. On Solaris (5.8), running a.out 50 will return
51. On Linux it crashes.
I digged through the source code. The original SunOS version (Solaris 5.8) was
using a global shared buffer (_rawcombuf). the clntraw_create will place the
request into this buffer, and svcraw_create will fetch the data from this
buffer, and use it for response.
In the current version of glibc, the buffers were separated, and made private
(and thread safe)- svc_raw.c, and clnt_raw.c. The change seems to be
"mechanical" - every global was made thread safe/static. May be someone just
converted the code - got it compiled - but did not have any test case for those
functions.
Since the buffers are separated - the interprocess code does not work!. Minimal
solution will be make _raw_buf - private for every thread.
I know that the those functions are not used very often. Unfortunately, they are
part of a large system that I'm porting to Linux, and I hope that I do not have
to re-implement the functions from scratch.
--
Summary: clntraw_create and svcraw_create do not communicate
Product: glibc
Version: 2.3.4
Status: NEW
Severity: critical
Priority: P2
Component: libc
AssignedTo: drepper at redhat dot com
ReportedBy: yair dot lenga at citi dot com
CC: glibc-bugs at sources dot redhat dot com
http://sourceware.org/bugzilla/show_bug.cgi?id=9890
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.