From: Sangchul Lee Date: Fri, 17 Apr 2020 03:50:46 +0000 (+0900) Subject: Comply with the Tizen coding rule X-Git-Tag: submit/tizen/20200420.013518^0 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=7c9964d68d4db6d1d7b1379fbab4f9fe2b5acc54;p=platform%2Fcore%2Fapi%2Fsound-manager.git Comply with the Tizen coding rule [Version] 0.6.5 [Issue Type] Coding convention Change-Id: I6e76d35b7860f1c9df53bc423a6f3aa124332dfa Signed-off-by: Sangchul Lee --- diff --git a/include/sound_manager.h b/include/sound_manager.h index 8ea0df6..b03075f 100644 --- a/include/sound_manager.h +++ b/include/sound_manager.h @@ -801,9 +801,9 @@ int sound_manager_apply_stream_routing(sound_stream_info_h stream_info); * @since_tizen 5.5 * * @remarks This function is to set a specific built-in device when the system has multiple devices of the same built-in device type. - * When there's only one device for a built-in device type in the system, nothing will happen even if this function succeeds in operation. - * If @a device is not supported by @a stream_info, #SOUND_MANAGER_ERROR_POLICY will be returned. - * After this function is called, @a device is not needed for the function's work. It's okay to destroy it by destroying the list from which it was obtained. + * When there's only one device for a built-in device type in the system, nothing will happen even if this function succeeds in operation. + * If @a device is not supported by @a stream_info, #SOUND_MANAGER_ERROR_POLICY will be returned. + * After this function is called, @a device is not needed for the function's work. It's okay to destroy it by destroying the list from which it was obtained. * * @param[in] stream_info The handle of stream information * @param[in] io_direction The IO direction of the device @@ -833,9 +833,9 @@ int sound_manager_set_stream_preferred_device(sound_stream_info_h stream_info, s * * @remarks This function is to return the preferred device id per each direction if it has been set. * If there is no preferred device for a given direction, the corresponding output value will be set to - * #SOUND_MANAGER_STREAM_NO_PREFERRED_DEVICE. - * You can get a device handle of the id value by using sound_manager_get_device_list(), - * sound_manager_get_next_device() and sound_manager_get_device_id(). + * #SOUND_MANAGER_STREAM_NO_PREFERRED_DEVICE. + * You can get a device handle of the id value by using sound_manager_get_device_list(), + * sound_manager_get_next_device() and sound_manager_get_device_id(). * * @param[in] stream_info The handle of stream information * @param[out] in_device_id The preferred input device id diff --git a/include/sound_manager_internal.h b/include/sound_manager_internal.h index 0a0f187..c326ee0 100644 --- a/include/sound_manager_internal.h +++ b/include/sound_manager_internal.h @@ -455,8 +455,8 @@ int sound_manager_remove_device_id_for_stream_routing(sound_stream_info_h stream * @since_tizen 5.5 * * @remarks This function is to set a specific built-in device id when the system has multiple devices of the same built-in device type. - * When there's only one device for a built-in device type in the system, nothing will happen even if this function succeeds in operation. - * If the device type of @a device_id is not supported by @a stream_info, #SOUND_MANAGER_ERROR_POLICY will be returned. + * When there's only one device for a built-in device type in the system, nothing will happen even if this function succeeds in operation. + * If the device type of @a device_id is not supported by @a stream_info, #SOUND_MANAGER_ERROR_POLICY will be returned. * * @param[in] stream_info The handle of stream information * @param[in] io_direction The IO direction of the device @@ -496,8 +496,8 @@ int sound_manager_set_stream_preferred_device_id(sound_stream_info_h stream_info * @since_tizen 5.5 * * @remarks This function is to set a device id to streams made by the specific stream type. - * The available stream types for this function are #SOUND_STREAM_TYPE_MEDIA, #SOUND_STREAM_TYPE_SYSTEM,\n - * #SOUND_STREAM_TYPE_VOICE_INFORMATION and #SOUND_STREAM_TYPE_VOICE_RECOGNITION. Otherwise, #SOUND_MANAGER_ERROR_POLICY will be returned. + * The available stream types for this function are #SOUND_STREAM_TYPE_MEDIA, #SOUND_STREAM_TYPE_SYSTEM,\n + * #SOUND_STREAM_TYPE_VOICE_INFORMATION and #SOUND_STREAM_TYPE_VOICE_RECOGNITION. Otherwise, #SOUND_MANAGER_ERROR_POLICY will be returned. * * @param[in] stream_type The type of stream * @param[in] io_direction The IO direction of the device @@ -527,9 +527,9 @@ int sound_manager_set_stream_preemptive_device(sound_stream_type_e stream_type, * * @remarks This function is to return the preemptive device id per each direction if it has been set. * If there is no preemptive device for a given direction, the corresponding output value will be set to - * #SOUND_MANAGER_STREAM_NO_PREEMPTIVE_DEVICE. - * You can get a device handle of the id value by using sound_manager_get_device_list(), - * sound_manager_get_next_device() and sound_manager_get_device_id(). + * #SOUND_MANAGER_STREAM_NO_PREEMPTIVE_DEVICE. + * You can get a device handle of the id value by using sound_manager_get_device_list(), + * sound_manager_get_next_device() and sound_manager_get_device_id(). * * @param[in] stream_type The type of stream * @param[out] in_device_id The preemptive input device id diff --git a/include/sound_manager_internal_tv.h b/include/sound_manager_internal_tv.h index 1f4ab7f..2b0a98f 100644 --- a/include/sound_manager_internal_tv.h +++ b/include/sound_manager_internal_tv.h @@ -409,8 +409,8 @@ int sound_manager_remove_device_id_for_stream_routing(sound_stream_info_h stream * @since_tizen 5.5 * * @remarks This function is to set a specific built-in device id when the system has multiple devices of the same built-in device type. - * When there's only one device for a built-in device type in the system, nothing will happen even if this function succeeds in operation. - * If the device type of @a device_id is not supported by @a stream_info, #SOUND_MANAGER_ERROR_POLICY will be returned. + * When there's only one device for a built-in device type in the system, nothing will happen even if this function succeeds in operation. + * If the device type of @a device_id is not supported by @a stream_info, #SOUND_MANAGER_ERROR_POLICY will be returned. * * @param[in] stream_info The handle of stream information * @param[in] io_direction The IO direction of the device @@ -450,8 +450,8 @@ int sound_manager_set_stream_preferred_device_id(sound_stream_info_h stream_info * @since_tizen 5.5 * * @remarks This function is to set a device id to streams made by the specific stream type. - * The available stream types for this function are #SOUND_STREAM_TYPE_MEDIA, #SOUND_STREAM_TYPE_SYSTEM,\n - * #SOUND_STREAM_TYPE_VOICE_INFORMATION and #SOUND_STREAM_TYPE_VOICE_RECOGNITION. Otherwise, #SOUND_MANAGER_ERROR_POLICY will be returned. + * The available stream types for this function are #SOUND_STREAM_TYPE_MEDIA, #SOUND_STREAM_TYPE_SYSTEM,\n + * #SOUND_STREAM_TYPE_VOICE_INFORMATION and #SOUND_STREAM_TYPE_VOICE_RECOGNITION. Otherwise, #SOUND_MANAGER_ERROR_POLICY will be returned. * * @param[in] stream_type The type of stream * @param[in] io_direction The IO direction of the device @@ -481,9 +481,9 @@ int sound_manager_set_stream_preemptive_device(sound_stream_type_e stream_type, * * @remarks This function is to return the preemptive device id per each direction if it has been set. * If there is no preemptive device for a given direction, the corresponding output value will be set to - * #SOUND_MANAGER_STREAM_NO_PREEMPTIVE_DEVICE. - * You can get a device handle of the id value by using sound_manager_get_device_list(), - * sound_manager_get_next_device() and sound_manager_get_device_id(). + * #SOUND_MANAGER_STREAM_NO_PREEMPTIVE_DEVICE. + * You can get a device handle of the id value by using sound_manager_get_device_list(), + * sound_manager_get_next_device() and sound_manager_get_device_id(). * * @param[in] stream_type The type of stream * @param[out] in_device_id The preemptive input device id diff --git a/packaging/capi-media-sound-manager.spec b/packaging/capi-media-sound-manager.spec index 0287646..a7228cf 100644 --- a/packaging/capi-media-sound-manager.spec +++ b/packaging/capi-media-sound-manager.spec @@ -1,6 +1,6 @@ Name: capi-media-sound-manager Summary: Sound Manager library -Version: 0.6.4 +Version: 0.6.5 Release: 0 Group: Multimedia/API License: Apache-2.0 diff --git a/src/sound_manager.c b/src/sound_manager.c index aaac929..f3636c3 100644 --- a/src/sound_manager.c +++ b/src/sound_manager.c @@ -192,9 +192,8 @@ int sound_manager_destroy_stream_information(sound_stream_info_h stream_info) SM_ENTER_CRITICAL_SECTION_WITH_RETURN(&stream_h->focus_state_mutex, MM_ERROR_SOUND_INTERNAL); ret = _destroy_pa_connection_and_unregister_focus(stream_h); SM_LEAVE_CRITICAL_SECTION(&stream_h->focus_state_mutex); - if (ret == MM_ERROR_NONE) { + if (ret == MM_ERROR_NONE) SM_SAFE_FREE(stream_h); - } return _convert_sound_manager_error_code(__func__, ret); } diff --git a/src/sound_manager_internal.c b/src/sound_manager_internal.c index b806ee2..2bf678c 100644 --- a/src/sound_manager_internal.c +++ b/src/sound_manager_internal.c @@ -848,4 +848,4 @@ int sound_manager_get_stream_preemptive_device(sound_stream_type_e stream_type, ret = _get_preemptive_device(stream_type, in_device_id, out_device_id); return _convert_sound_manager_error_code(__func__, ret); -} \ No newline at end of file +} diff --git a/test/sound_manager_test.c b/test/sound_manager_test.c index ea8d51b..e79ee4e 100644 --- a/test/sound_manager_test.c +++ b/test/sound_manager_test.c @@ -1877,7 +1877,7 @@ static void interpret(char *cmd) preferred_device_id = atoi(cmd); cnt++; } else if (cnt == 1) { - switch ( atoi(cmd)) { + switch (atoi(cmd)) { case 0: direction = SOUND_DEVICE_IO_DIRECTION_OUT; break;