From 558ef9152648cbfd9ad1328ccae3813b0b8e4862 Mon Sep 17 00:00:00 2001 From: "sunm.lee" Date: Fri, 13 May 2016 09:25:05 +0900 Subject: [PATCH] runtime-info: fix - close the file pointer Close file pointer cpuinfo_fp at runtime_info_get_frequency_cpuinfo() when function returns. Change-Id: Id66f3507d2b40a89e00e216dd951749b36dcd803 Signed-off-by: sunm.lee --- src/runtime_info_system.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/runtime_info_system.c b/src/runtime_info_system.c index fe8b10e..2761305 100644 --- a/src/runtime_info_system.c +++ b/src/runtime_info_system.c @@ -354,10 +354,12 @@ int runtime_info_get_frequency_cpuinfo(int core_idx, int *cpu_freq) } *cpu_freq = acc_freq; + fclose(cpuinfo_fp); return RUNTIME_INFO_ERROR_NONE; } ++cur_core; } + fclose(cpuinfo_fp); return RUNTIME_INFO_ERROR_NOT_SUPPORTED; } -- 2.7.4