fixup! Enhance session backward compatibility 18/121218/1 accepted/tizen_common accepted/tizen_ivi accepted/tizen_mobile accepted/tizen_tv accepted/tizen_wearable accepted/tizen/common/20170329.172623 accepted/tizen/ivi/20170329.222747 accepted/tizen/mobile/20170329.222615 accepted/tizen/tv/20170329.222658 accepted/tizen/unified/20170329.222806 accepted/tizen/wearable/20170329.222722 submit/tizen/20170329.121135
authorSangchul Lee <sc11.lee@samsung.com>
Mon, 27 Mar 2017 07:52:49 +0000 (16:52 +0900)
committerJeongho Mok <jho.mok@samsung.com>
Mon, 27 Mar 2017 08:44:38 +0000 (01:44 -0700)
Fix invalid length to compare ext_info array with predefined string

[Version] 0.10.106
[Profile] Common
[Issue Type] Bug fix

Change-Id: I68b82e8f2f71f216bf940c450841387f438a48bb
Signed-off-by: Sangchul Lee <sc11.lee@samsung.com>
(cherry picked from commit 8023d0a8d478ef695172eb541fd3e837cc06e34f)

focus_server/mm_sound_mgr_focus.c
packaging/libmm-sound.spec

index 7d87eca..4f99220 100644 (file)
@@ -881,10 +881,10 @@ static void update_reacquisition_with_released_state(focus_node_t *node, int dir
        /* In case of session backward compatibility for audio-io, mm-player, mm-camcorder, we mark a specific flag here.
         When invoking focus state changed callback for acquiring, state of the node will not be updated rather updated
         when the next request to acquire. */
-       if (!strncmp("audio-io acquire focus", node->ext_info[direction], strlen(node->ext_info[direction])) ||
-               !strncmp("mm-player acquire focus", node->ext_info[direction], strlen(node->ext_info[direction])) ||
-               !strncmp("mm-camcorder acquire focus", node->ext_info[direction], strlen(node->ext_info[direction]))) {
-               debug_msg("this node needs reacquisition with focus released state\n");
+       if (!strncmp("audio-io acquire focus", node->ext_info[direction], MM_SOUND_NAME_NUM) ||
+           !strncmp("mm-player acquire focus", node->ext_info[direction], MM_SOUND_NAME_NUM) ||
+           !strncmp("mm-camcorder acquire focus", node->ext_info[direction], MM_SOUND_NAME_NUM)) {
+               debug_msg("this node[pid:%d, handle_id:%d] needs reacquisition with focus released state\n", node->pid, node->handle_id);
                node->reacquisition_with_released_state = true;
        }
 }
index 428463b..c50bd49 100644 (file)
@@ -1,6 +1,6 @@
 Name:       libmm-sound
 Summary:    MMSound Package contains client lib and sound_server binary
-Version:    0.10.105
+Version:    0.10.106
 Release:    0
 Group:      System/Libraries
 License:    Apache-2.0