diff options
author | Ken'ichi Ohmichi <oomichi@mxs.nes.nec.co.jp> | 2009-05-08 01:52:46 +0530 |
---|---|---|
committer | Balbir Singh <balbir@linux.vnet.ibm.com> | 2009-05-08 01:52:46 +0530 |
commit | df06bb605d9c336e6cc60de3007b72de09dc77e5 (patch) | |
tree | 9947d0fbef2fd312a0b1e528955ac32f9ba716bd /src/tools/cgexec.c | |
parent | 8953fc07c0498d1ddd9a04dc549ffb85862f4c5f (diff) | |
download | libcg-df06bb605d9c336e6cc60de3007b72de09dc77e5.tar.gz libcg-df06bb605d9c336e6cc60de3007b72de09dc77e5.tar.xz libcg-df06bb605d9c336e6cc60de3007b72de09dc77e5.zip |
I tested a cgrlesengd daemon with huge load, which makes many 'su',
in long time. And the daemon was killed by an OOM killer. So the
daemon has memory leak. This patch fixes this problem.
The daemon allocates memory at cg_prepare_cgroup(), but it does not
free the memory. This patch adds necessary free() to cgroup_change_
cgroup_path by calling cgroup_free_controllers(). In addition, this
patch adds free()s for handling error and flushes the counters of the
allocations in cgroup_free_controllers().
Signed-off-by: Ken'ichi Ohmichi <oomichi@mxs.nes.nec.co.jp>
Signed-off-by: Balbir Singh <balbir@linux.vnet.ibm.com>
Diffstat (limited to 'src/tools/cgexec.c')
0 files changed, 0 insertions, 0 deletions