coverity: #1437027

Read from pointer after free Signed-off-by: 's avatarChristian Brauner <christian.brauner@ubuntu.com>
parent b5710d3c
......@@ -807,8 +807,8 @@ static void ls_print_fancy_format(struct ls *l, struct lengths *lht,
strcasecmp(*s, "SWAP") && strcasecmp(*s, "AUTOSTART") &&
strcasecmp(*s, "GROUPS") && strcasecmp(*s, "INTERFACE") &&
strcasecmp(*s, "IPV4") && strcasecmp(*s, "IPV6")) {
lxc_free_array((void **)tmp, free);
fprintf(stderr, "Invalid key: %s\n", *s);
lxc_free_array((void **)tmp, free);
return;
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment