projects
/
cascardo
/
ovs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1caf063
)
json: Fix leaked nodes in json_hash_object()
author
Thomas Graf
<tgraf@noironetworks.com>
Tue, 26 Aug 2014 10:23:03 +0000
(12:23 +0200)
committer
Ben Pfaff
<blp@nicira.com>
Tue, 26 Aug 2014 16:13:38 +0000
(09:13 -0700)
nodes is allocated through shash_sort() but never freed.
Signed-off-by: Thomas Graf <tgraf@noironetworks.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
lib/json.c
patch
|
blob
|
history
diff --git
a/lib/json.c
b/lib/json.c
index
167c40c
..
9c819d7
100644
(file)
--- a/
lib/json.c
+++ b/
lib/json.c
@@
-461,6
+461,7
@@
json_hash_object(const struct shash *object, size_t basis)
basis = hash_string(node->name, basis);
basis = json_hash(node->data, basis);
}
+ free(nodes);
return basis;
}