]> git.pld-linux.org Git - packages/libtirpc.git/commitdiff
- Fixed mutex locking problem in clnt_raw.c. One should grab the
authorJan Rękorajski <baggins@pld-linux.org>
Tue, 8 May 2007 11:49:57 +0000 (11:49 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
  clntraw_lock before accessing at clntraw_private, not after.

Changed files:
    libtirpc-mutex.patch -> 1.1

libtirpc-mutex.patch [new file with mode: 0644]

diff --git a/libtirpc-mutex.patch b/libtirpc-mutex.patch
new file mode 100644 (file)
index 0000000..7f723e9
--- /dev/null
@@ -0,0 +1,19 @@
+diff --git a/src/clnt_raw.c b/src/clnt_raw.c
+index 153dd87..36035c8 100644
+--- a/src/clnt_raw.c
++++ b/src/clnt_raw.c
+@@ -82,12 +82,13 @@ clnt_raw_create(prog, vers)
+       rpcprog_t prog;
+       rpcvers_t vers;
+ {
+-      struct clntraw_private *clp = clntraw_private;
++      struct clntraw_private *clp;
+       struct rpc_msg call_msg;
+       XDR *xdrs = &clp->xdr_stream;
+       CLIENT  *client = &clp->client_object;
+       mutex_lock(&clntraw_lock);
++      clp = clntraw_private;
+       if (clp == NULL) {
+               clp = (struct clntraw_private *)calloc(1, sizeof (*clp));
+               if (clp == NULL) {
This page took 0.069746 seconds and 4 git commands to generate.