Skip locking focus_state mutex if sound_manager_get_focus_state() is called in focus... 30/266030/1 accepted/tizen/unified/20211109.042859 submit/tizen/20211108.065142 submit/tizen/20211108.233216
authorSangchul Lee <sc11.lee@samsung.com>
Thu, 4 Nov 2021 06:50:55 +0000 (15:50 +0900)
committerSangchul Lee <sc11.lee@samsung.com>
Thu, 4 Nov 2021 06:51:42 +0000 (15:51 +0900)
commit81799a4a2f2921a4d5fc22656ccc64d4234688d1
treeb7c5432e2e24084e131ec654243af0b3bc3b2653
parentfe0109f5862d420053ce7fa463a3aa878f89fc9d
Skip locking focus_state mutex if sound_manager_get_focus_state() is called in focus callback

During destroying handle, it is possible that the focus state callback is
called simultaneously. The destroy function already lock the mutex also,
deadlock can occur if user calls the sound_manager_get_focus_state() function
inside of the focus state callback context. It is now fixed with this patch.

[Version] 0.6.39
[Issue Type] Improvement

Change-Id: I092d127fb8e29dc5fea0056d3b4f1da101130f3d
Signed-off-by: Sangchul Lee <sc11.lee@samsung.com>
packaging/capi-media-sound-manager.spec
src/sound_manager.c