aboutsummaryrefslogtreecommitdiffstats
path: root/tools/perf/util/symbol-minimal.c
diff options
context:
space:
mode:
authorJames Morris <james.l.morris@oracle.com>2014-04-14 11:23:14 +1000
committerJames Morris <james.l.morris@oracle.com>2014-04-14 11:23:14 +1000
commitecd740c6f2f092b90b95fa35f757973589eaaca2 (patch)
treece02b1e18c4fc5729699251460cd8be7604d8401 /tools/perf/util/symbol-minimal.c
parentselinux: correctly label /proc inodes in use before the policy is loaded (diff)
parentLinux 3.14 (diff)
downloadlinux-dev-ecd740c6f2f092b90b95fa35f757973589eaaca2.tar.xz
linux-dev-ecd740c6f2f092b90b95fa35f757973589eaaca2.zip
Merge commit 'v3.14' into next
Diffstat (limited to 'tools/perf/util/symbol-minimal.c')
-rw-r--r--tools/perf/util/symbol-minimal.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/tools/perf/util/symbol-minimal.c b/tools/perf/util/symbol-minimal.c
index 2d2dd0532b5a..bd15f490d04f 100644
--- a/tools/perf/util/symbol-minimal.c
+++ b/tools/perf/util/symbol-minimal.c
@@ -1,4 +1,5 @@
#include "symbol.h"
+#include "util.h"
#include <stdio.h>
#include <fcntl.h>
@@ -253,6 +254,7 @@ int symsrc__init(struct symsrc *ss, struct dso *dso __maybe_unused,
if (!ss->name)
goto out_close;
+ ss->fd = fd;
ss->type = type;
return 0;
@@ -274,7 +276,7 @@ bool symsrc__has_symtab(struct symsrc *ss __maybe_unused)
void symsrc__destroy(struct symsrc *ss)
{
- free(ss->name);
+ zfree(&ss->name);
close(ss->fd);
}