projects
/
citadel.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
35c9050
)
Fixed a double free error in serv_openid_rp.c
author
Art Cancro
<ajc@citadel.org>
Mon, 2 Jun 2008 14:24:40 +0000
(14:24 +0000)
committer
Art Cancro
<ajc@citadel.org>
Mon, 2 Jun 2008 14:24:40 +0000
(14:24 +0000)
citadel/modules/openid/serv_openid_rp.c
patch
|
blob
|
history
diff --git
a/citadel/modules/openid/serv_openid_rp.c
b/citadel/modules/openid/serv_openid_rp.c
index 4a87abc88996a2d0eb2f68b96ba02d5e35c054fd..bd883bf31e4b6110463879a2218a8aa0eaeca3d0 100644
(file)
--- a/
citadel/modules/openid/serv_openid_rp.c
+++ b/
citadel/modules/openid/serv_openid_rp.c
@@
-501,7
+501,6
@@
void cmd_oidf(char *argbuf) {
char thiskey[1024];
char thisdata[1024];
HashList *keys = NULL;
char thiskey[1024];
char thisdata[1024];
HashList *keys = NULL;
- HashPos *HashPos;
struct ctdl_openid *oiddata = (struct ctdl_openid *) CC->openid_data;
keys = NewHash(1, NULL);
struct ctdl_openid *oiddata = (struct ctdl_openid *) CC->openid_data;
keys = NewHash(1, NULL);
@@
-662,18
+661,21
@@
void cmd_oidf(char *argbuf) {
}
cprintf("000\n");
}
cprintf("000\n");
- /* Free the hash list */
+ /*
+ * We will eventually do something with the data in the hash list.
+ *
long len;
void *Value;
char *Key;
long len;
void *Value;
char *Key;
-
+ HashPos *HashPos;
HashPos = GetNewHashPos();
while (GetNextHashPos(keys, HashPos, &len, &Key, &Value)!=0)
{
HashPos = GetNewHashPos();
while (GetNextHashPos(keys, HashPos, &len, &Key, &Value)!=0)
{
- free(Value);
}
DeleteHashPos(&HashPos);
}
DeleteHashPos(&HashPos);
- DeleteHash(&keys);
+ */
+
+ DeleteHash(&keys); /* This will free() all the key data for us */
}
}