projects
/
platform
/
upstream
/
systemd.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
402a81c
)
nspawn: fix memleak
author
Zbigniew Jędrzejewski-Szmek
<zbyszek@in.waw.pl>
Sun, 15 Jan 2017 21:57:57 +0000
(16:57 -0500)
committer
Zbigniew Jędrzejewski-Szmek
<zbyszek@in.waw.pl>
Sun, 15 Jan 2017 21:57:57 +0000
(16:57 -0500)
CID #1368262: fn is allocated with new, so it should be freed.
src/nspawn/nspawn.c
patch
|
blob
|
history
diff --git
a/src/nspawn/nspawn.c
b/src/nspawn/nspawn.c
index
6396a69
..
78ae2f4
100644
(file)
--- a/
src/nspawn/nspawn.c
+++ b/
src/nspawn/nspawn.c
@@
-3470,8
+3470,8
@@
static int run(int master,
}
static int load_root_hash(const char *image) {
- _cleanup_free_ char *text = NULL;
- char *
fn, *
n, *e;
+ _cleanup_free_ char *text = NULL
, *fn = NULL
;
+ char *n, *e;
void *k;
size_t l;
int r;