From e98eab69adbedc5ad884d62a2e2ef8b96756aed2 Mon Sep 17 00:00:00 2001 From: Sangchul Lee Date: Thu, 10 May 2018 12:21:22 +0900 Subject: [PATCH] Correct signature of internal function that does not require return value svace info : Redundant comparison 'ret' == '0' (0 == 0) is always true at mm_sound_plugin_codec_wave.c:604. [Version] 0.12.17 [Issue Type] SVACE (WGID 34314) Change-Id: I9e89b3fca2b98f45a5e97ae30fb6a122ed2689d5 Signed-off-by: Sangchul Lee --- packaging/libmm-sound.spec | 2 +- server/plugin/wav/mm_sound_plugin_codec_wave.c | 9 +++------ 2 files changed, 4 insertions(+), 7 deletions(-) diff --git a/packaging/libmm-sound.spec b/packaging/libmm-sound.spec index 3b5668f..af47ece 100644 --- a/packaging/libmm-sound.spec +++ b/packaging/libmm-sound.spec @@ -1,6 +1,6 @@ Name: libmm-sound Summary: MMSound Package contains client lib and sound_server binary -Version: 0.12.16 +Version: 0.12.17 Release: 0 Group: System/Libraries License: Apache-2.0 diff --git a/server/plugin/wav/mm_sound_plugin_codec_wave.c b/server/plugin/wav/mm_sound_plugin_codec_wave.c index 563f3b1..2b9ccf6 100644 --- a/server/plugin/wav/mm_sound_plugin_codec_wave.c +++ b/server/plugin/wav/mm_sound_plugin_codec_wave.c @@ -451,7 +451,7 @@ static void _pa_stream_uncork(wave_info_t *h) pa_threaded_mainloop_unlock(h->m); } -static int _pa_stream_stop_disconnect(wave_info_t *h) +static void _pa_stream_stop_disconnect(wave_info_t *h) { assert(h); assert(h->m); @@ -471,8 +471,6 @@ static int _pa_stream_stop_disconnect(wave_info_t *h) pa_threaded_mainloop_free(h->m); h->m = NULL; - - return 0; } static int* _mm_sound_plug_codec_wave_get_supported_types(void) @@ -581,7 +579,6 @@ static int _mm_sound_plug_codec_wave_play(MMHandleType handle) static int _mm_sound_plug_codec_wave_stop(MMHandleType handle) { - int ret = 0; wave_info_t *p = (wave_info_t*) handle; if (!p) { @@ -591,12 +588,12 @@ static int _mm_sound_plug_codec_wave_stop(MMHandleType handle) debug_msg("Handle %p stop requested", p); - ret = _pa_stream_stop_disconnect(p); + _pa_stream_stop_disconnect(p); if (p->stop_cb) p->stop_cb(p->cb_param); - return (ret == 0) ? MM_ERROR_NONE : MM_ERROR_SOUND_INTERNAL; + return MM_ERROR_NONE; } static int _mm_sound_plug_codec_wave_destroy(MMHandleType handle) -- 2.7.4