cg: props -- Fix resource leak on realloc failure
| *** CID 161426: Resource leaks (RESOURCE_LEAK)
| /criu/cgroup-props.c: 318 in cgp_parse_stream()
| 312 }
| 313
| 314 if (xrealloc_safe(&cgp_entry->cgp.props,
| 315 (cgp_entry->cgp.nr_props + 1) * sizeof(char *))) {
| 316 pr_err("Can't allocate property for controller %s\n",
| 317 cgp_entry->cgp.name);
| >>> CID 161426: Resource leaks (RESOURCE_LEAK)
| >>> Variable "cgp_entry" going out of scope leaks the storage it points to.
| 318 return -1;
| 319 }
Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
Signed-off-by:
Pavel Emelyanov <xemul@virtuozzo.com>
Showing
Please
register
or
sign in
to comment