Fix Svace issue 54/63854/1 accepted/tizen/common/20160329.050700 accepted/tizen/ivi/20160405.005423 accepted/tizen/mobile/20160405.005334 accepted/tizen/tv/20160405.005350 accepted/tizen/wearable/20160405.005408 submit/tizen/20160328.061759
authorDoHyun Pyun <dh79.pyun@samsung.com>
Mon, 28 Mar 2016 06:15:16 +0000 (15:15 +0900)
committerDoHyun Pyun <dh79.pyun@samsung.com>
Mon, 28 Mar 2016 06:15:16 +0000 (15:15 +0900)
WGID 58558: PROC_USE.VULNERABLE

Change-Id: Icf425b22f799a86370a41172962ac041f2278bac
Signed-off-by: DoHyun Pyun <dh79.pyun@samsung.com>
hf-agent/bluetooth-hf-agent.c

index a63fca0..929a1b4 100755 (executable)
@@ -765,7 +765,7 @@ static gboolean __bt_hf_monitor_timer_cb(gpointer data)
 
                /* In the case of ATD, prev_cmd will be always ATD, because we will not
                 * allow further commands. For safer side again set prev_cmd as ATD */
-               strcpy(prev_cmd, "ATD");
+               strncpy(prev_cmd, "ATD\0", BT_HF_CMD_BUF_SIZE - 1);
        }
        hf_handle_rx_at_cmd(&bt_hf_info, BT_HF_ERROR_RESP);