Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 625b757c authored by jianzhou's avatar jianzhou
Browse files

ANDROID: Fix slab memory leakage issue



lowmem_scan call get_task_struct twice, which causes memory leakage.

Remove the duplicated get_task_struct which was invoked by LTS.

Change-Id: I2a3374f63cd2ec034f9e794917587a04d3975484
Signed-off-by: default avatarjianzhou <jianzhou@codeaurora.org>
parent 008355f5
Loading
Loading
Loading
Loading
+0 −2
Original line number Diff line number Diff line
@@ -817,8 +817,6 @@ static unsigned long lowmem_scan(struct shrinker *s, struct shrink_control *sc)
		trace_almk_shrink(selected_tasksize, ret,
				  other_free, other_file,
				  selected_oom_score_adj);

		get_task_struct(selected);
	} else {
		trace_almk_shrink(1, ret, other_free, other_file, 0);
		rcu_read_unlock();