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

Commit 152a3141 authored by Kiran Gunda's avatar Kiran Gunda
Browse files

msm: msm_bus: fix the memory leak issue



Client name allocated dynamically during the registration
is not freed at the time of unregistration. This is
leading to memory leak issue. This patch fixes the issue
by freeing up the client name during unregistartion time.

Change-Id: I0fe75ce71fdf0ee9a1268d52ac244047cc3413d7
Signed-off-by: default avatarKiran Gunda <kgunda@codeaurora.org>
parent 17d7bd58
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -1351,6 +1351,7 @@ static void unregister_adhoc(struct msm_bus_client_handle *cl)
				cl->first_hop, cl->active_only);
	commit_data();
	msm_bus_dbg_remove_client(cl);
	kfree(cl->name);
	kfree(cl);
exit_unregister_client:
	rt_mutex_unlock(&msm_bus_adhoc_lock);