projects
/
project
/
netifd.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
interface-ip: fix memory leak on error in interface_update_prefix_assignments()
[project/netifd.git]
/
interface-ip.c
diff --git
a/interface-ip.c
b/interface-ip.c
index
6726a69
..
27e9e41
100644
(file)
--- a/
interface-ip.c
+++ b/
interface-ip.c
@@
-994,8
+994,10
@@
static void interface_update_prefix_assignments(struct device_prefix *prefix, bo
}
entry = calloc(1, sizeof(*entry));
- if (!entry)
+ if (!entry) {
+ free(c);
continue;
+ }
entry->node.key = c;
avl_insert(&assign_later, &entry->node);