summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHari Bathini <hbathini@linux.vnet.ibm.com>2017-08-29 23:08:02 +0530
committerSimon Horman <horms@verge.net.au>2017-08-30 08:38:07 +0200
commit69431282f075ab723c4886f20aa248976920aaae (patch)
tree638774c74da00d31cc17495a7e1c777bdafa9c01
parentaec4d0f7a2502a13fc21e90ff32dc306b0ad1190 (diff)
kexec-tools: ppc64: fix leak while checking for coherent device memory
Signed-off-by: Hari Bathini <hbathini@linux.vnet.ibm.com> Signed-off-by: Simon Horman <horms@verge.net.au>
-rw-r--r--kexec/arch/ppc64/crashdump-ppc64.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/kexec/arch/ppc64/crashdump-ppc64.c b/kexec/arch/ppc64/crashdump-ppc64.c
index 7ea3983..bc9f948 100644
--- a/kexec/arch/ppc64/crashdump-ppc64.c
+++ b/kexec/arch/ppc64/crashdump-ppc64.c
@@ -217,6 +217,7 @@ static int is_coherent_device_mem(const char *fname)
break;
}
if (!strncmp(buf, "ibm,coherent-device-memory", 26)) {
+ fclose(file);
ret = 1;
break;
}