[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] r2286 - GNUnet/src/applications/rpc
From: |
grothoff |
Subject: |
[GNUnet-SVN] r2286 - GNUnet/src/applications/rpc |
Date: |
Sun, 27 Nov 2005 11:43:35 -0800 (PST) |
Author: grothoff
Date: 2005-11-27 11:43:33 -0800 (Sun, 27 Nov 2005)
New Revision: 2286
Modified:
GNUnet/src/applications/rpc/parameterstest.c
Log:
fixing double free
Modified: GNUnet/src/applications/rpc/parameterstest.c
===================================================================
--- GNUnet/src/applications/rpc/parameterstest.c 2005-11-23 18:56:01 UTC
(rev 2285)
+++ GNUnet/src/applications/rpc/parameterstest.c 2005-11-27 19:43:33 UTC
(rev 2286)
@@ -53,17 +53,17 @@
p = RPC_paramDeserialize(buf,
size);
FREE(buf);
- if (p == NULL)
+ if (p == NULL)
return 1;
-
+ buf = NULL;
if (OK != RPC_paramValueByName(p,
"foo",
&len,
&buf))
return 1;
- if (strcmp("bar", buf) != 0)
+ if (strcmp("bar", buf) != 0)
return 1;
- FREE(buf);
+ buf = NULL;
if (4 != len)
return 1;
if (OK != RPC_paramValueByPosition(p,
@@ -71,21 +71,20 @@
&len,
&buf))
return 1;
- if (strcmp("foo", buf) != 0)
+ if (strcmp("foo", buf) != 0)
return 1;
- FREE(buf);
if (4 != len)
return 1;
if (SYSERR != RPC_paramValueByPosition(p,
2,
&len,
- &buf))
+ &buf))
return 1;
if (SYSERR != RPC_paramValueByName(p,
"not there",
&len,
- &buf))
+ &buf))
return 1;
RPC_paramFree(p);
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [GNUnet-SVN] r2286 - GNUnet/src/applications/rpc,
grothoff <=