tools: fix memory leakage issue in acrnlog.c
In function mk_dir(), handler 'dir' returned by opendir() is not released before function return and results in memory leakage. Tracked-On: #7098 Signed-off-by: Yonghua Huang <yonghua.huang@intel.com>
This commit is contained in:
parent
13ce55ef4f
commit
9699353a08
|
@ -414,6 +414,7 @@ static int mk_dir(const char *path)
|
|||
} else
|
||||
remove(acrnlog_file);
|
||||
}
|
||||
closedir(dir);
|
||||
}
|
||||
|
||||
return 0;
|
||||
|
|
Loading…
Reference in New Issue