Replace glib threadpool usage with a 'dumb' thread implementation.
[platform/upstream/iotivity.git] / resource / csdk / connectivity / src / wifi_adapter / tizen / cawifiserver.c
index ac43454..b3f19f1 100644 (file)
@@ -113,9 +113,9 @@ static bool g_stopSecureUnicast = false;
 
 /**
  * @var g_threadPool
- * @brief ThreadPool for storing u_thread_pool_t handle passed from adapter
+ * @brief ThreadPool for storing ca_thread_pool_t handle passed from adapter
  */
-static u_thread_pool_t g_threadPool = NULL;
+static ca_thread_pool_t g_threadPool = NULL;
 
 /**
  * @var g_multicastServerInterface
@@ -428,7 +428,7 @@ static CAResult_t CAStartUnicastServer(const char *localAddress, uint16_t *port,
     ctx->stopFlag = &g_stopUnicast;
     ctx->socket_fd = *serverFD;
     ctx->type = isSecured ? CA_SECURED_UNICAST_SERVER : CA_UNICAST_SERVER;
-    if (CA_STATUS_OK != u_thread_pool_add_task(g_threadPool, CAReceiveHandler, (void *)ctx))
+    if (CA_STATUS_OK != ca_thread_pool_add_task(g_threadPool, CAReceiveHandler, (void *)ctx))
     {
         OIC_LOG(ERROR, WIFI_SERVER_TAG, "Failed to create read thread!");
         OICFree(ctx);
@@ -510,7 +510,7 @@ static CAResult_t CAWiFiServerCreateMutex(void)
     return CA_STATUS_OK;
 }
 
-CAResult_t CAWiFiInitializeServer(const u_thread_pool_t threadPool)
+CAResult_t CAWiFiInitializeServer(const ca_thread_pool_t threadPool)
 {
     OIC_LOG(DEBUG, WIFI_SERVER_TAG, "IN");
 
@@ -691,7 +691,7 @@ CAResult_t CAWiFiStartMulticastServer(const char *localAddress, const char *mult
     ctx->type = CA_MULTICAST_SERVER;
 
     g_stopMulticast = false;
-    if (CA_STATUS_OK != u_thread_pool_add_task(g_threadPool, CAReceiveHandler, (void *)ctx))
+    if (CA_STATUS_OK != ca_thread_pool_add_task(g_threadPool, CAReceiveHandler, (void *)ctx))
     {
         OIC_LOG(ERROR, WIFI_SERVER_TAG, "thread_pool_add_task failed!");