From: Phil Carmody Date: Wed, 26 May 2010 21:42:43 +0000 (-0700) Subject: mm: memcontrol - uninitialised return value X-Git-Tag: v2.6.35-rc1~192 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=315c1998e10527ff364a9883048455e609bc7232;p=platform%2Fkernel%2Flinux-3.10.git mm: memcontrol - uninitialised return value Only an out of memory error will cause ret to be set. Signed-off-by: Phil Carmody Acked-by: Kirill A. Shutemov Cc: Balbir Singh Cc: Daisuke Nishimura Acked-by: KAMEZAWA Hiroyuki Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/mm/memcontrol.c b/mm/memcontrol.c index 93b0239..8c200e8 100644 --- a/mm/memcontrol.c +++ b/mm/memcontrol.c @@ -3563,7 +3563,7 @@ static int mem_cgroup_usage_unregister_event(struct cgroup *cgrp, int type = MEMFILE_TYPE(cft->private); u64 usage; int size = 0; - int i, j, ret; + int i, j, ret = 0; mutex_lock(&memcg->thresholds_lock); if (type == _MEM)