Remove unused local variable and codes - wait_for_async( ) 28/188928/2
authorTaesoo Jun <steve.jun@samsung.com>
Wed, 12 Sep 2018 02:45:44 +0000 (11:45 +0900)
committerDoHyun Pyun <dh79.pyun@samsung.com>
Wed, 12 Sep 2018 05:02:33 +0000 (14:02 +0900)
Change-Id: Ib9c2e29d3ee4f6e4ca3240e3f8633fff15655021
Signed-off-by: Taesoo Jun <steve.jun@samsung.com>
bt-oal/haltest/bluetooth_hal_tc.cpp

index 482c6df..f53d4f4 100644 (file)
@@ -53,13 +53,14 @@ static gboolean timeout_func(gpointer data)
 static void wait_for_async(int timeout)
 {
     int timeout_id = 0;
+
     mainloop = g_main_loop_new(NULL, FALSE);
 
     timeout_id = g_timeout_add(timeout, timeout_func, mainloop);
+    if (timeout_id < 0)
+        return;
+
     g_main_loop_run(mainloop);
-/*
-    g_source_remove(timeout_id);
-*/
 }
 
 static void __bt_oal_event_receiver(int event_type, gpointer event_data, gsize len)