Have ondemand_connected always return TRUE
authorSamuel Ortiz <sameo@linux.intel.com>
Sat, 24 Jul 2010 09:51:28 +0000 (11:51 +0200)
committerSamuel Ortiz <sameo@linux.intel.com>
Mon, 26 Jul 2010 10:22:21 +0000 (12:22 +0200)
For now ondemand_connected() always return TRUE as the ondemand feature
is not complete yet.

src/ondemand.c

index 64d7d0f..2d8cf93 100644 (file)
@@ -55,7 +55,8 @@ gboolean connman_ondemand_connected(void)
 {
        DBG("connected %d", connected);
 
-       return connected;
+       return TRUE;
+//     return connected;
 }
 
 int connman_ondemand_start(const char *bearer, unsigned int idle_timeout)
@@ -68,6 +69,8 @@ int connman_ondemand_start(const char *bearer, unsigned int idle_timeout)
        g_atomic_int_inc(&started);
 
        ondemand_service = __connman_session_request(bearer, "__ondemand__");
+       if (ondemand_service == NULL)
+               g_atomic_int_set(&started, 0);
 
        /* TODO:
         * 1) Set IDLETIMER target.