projects
/
oweals
/
netifd.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b409c78
)
system-linux: fix memory leak on error in system_add_vxlan()
author
Hans Dedecker
<dedeckeh@gmail.com>
Thu, 12 Apr 2018 20:14:52 +0000
(22:14 +0200)
committer
Hans Dedecker
<dedeckeh@gmail.com>
Thu, 12 Apr 2018 20:16:50 +0000
(22:16 +0200)
Detected by coverity in CID
1412449
Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
system-linux.c
patch
|
blob
|
history
diff --git
a/system-linux.c
b/system-linux.c
index 0ca525602d9ea63ac5b845b2be9c6c7bdec7c26c..6fb0a01bf20c9b117c729fa3a04c20b8f9cc2fef 100644
(file)
--- a/
system-linux.c
+++ b/
system-linux.c
@@
-2824,8
+2824,10
@@
static int system_add_vxlan(const char *name, const unsigned int link, struct bl
unsigned tos = 1;
if (strcmp(str, "inherit")) {
- if (!system_tos_aton(str, &tos))
- return -EINVAL;
+ if (!system_tos_aton(str, &tos)) {
+ ret = -EINVAL;
+ goto failure;
+ }
}
nla_put_u8(msg, IFLA_VXLAN_TOS, tos);