Add line coverage tags
[platform/core/uifw/stt.git] / client / stt_client.c
index 793bfd7..a9eef07 100644 (file)
@@ -43,13 +43,13 @@ int stt_client_new(stt_h* stt)
 
        client = (stt_client_s*)calloc(1, sizeof(stt_client_s));
        if (NULL == client) {
-               SLOG(LOG_ERROR, TAG_STTC, "[ERROR] Fail to allocate memory");
+               SLOG(LOG_ERROR, TAG_STTC, "[ERROR] Fail to allocate memory"); //LCOV_EXCL_LINE
                return STT_ERROR_OUT_OF_MEMORY;
        }
 
        stt_h temp = (stt_h)calloc(1, sizeof(struct stt_s));
        if (NULL == temp) {
-               SLOG(LOG_ERROR, TAG_STTC, "[ERROR] Fail to allocate memory");
+               SLOG(LOG_ERROR, TAG_STTC, "[ERROR] Fail to allocate memory"); //LCOV_EXCL_LINE
                free(client);
                return STT_ERROR_OUT_OF_MEMORY;
        }
@@ -94,6 +94,8 @@ int stt_client_new(stt_h* stt)
 
        client->cb_ref_count = 0;
 
+       client->internal = false;
+
        g_client_list = g_list_append(g_client_list, client);
 
        *stt = temp;
@@ -104,7 +106,7 @@ int stt_client_new(stt_h* stt)
 int stt_client_destroy(stt_h stt)
 {
        if (stt == NULL) {
-               SLOG(LOG_ERROR, TAG_STTC, "Input parameter is NULL");
+               SLOG(LOG_ERROR, TAG_STTC, "Input parameter is NULL"); //LCOV_EXCL_LINE
                return 0;
        }
 
@@ -152,7 +154,7 @@ int stt_client_destroy(stt_h stt)
                }
        }
 
-       SLOG(LOG_ERROR, TAG_STTC, "[ERROR] client Not founded");
+       SLOG(LOG_ERROR, TAG_STTC, "[ERROR] client Not founded"); //LCOV_EXCL_LINE
 
        return -1;
 }
@@ -161,7 +163,7 @@ int stt_client_destroy(stt_h stt)
 stt_client_s* stt_client_get(stt_h stt)
 {
        if (NULL == stt) {
-               SLOG(LOG_ERROR, TAG_STTC, "[ERROR] Input parameter is NULL");
+               SLOG(LOG_ERROR, TAG_STTC, "[ERROR] Input parameter is NULL"); //LCOV_EXCL_LINE
                return NULL;
        }
 
@@ -191,7 +193,7 @@ stt_client_s* stt_client_get(stt_h stt)
 stt_client_s* stt_client_get_by_uid(const int uid)
 {
        if (uid < 0) {
-               SLOG(LOG_ERROR, TAG_STTC, "[ERROR] out of range : handle");
+               SLOG(LOG_ERROR, TAG_STTC, "[ERROR] out of range : handle"); //LCOV_EXCL_LINE
                return NULL;
        }
 
@@ -213,7 +215,7 @@ stt_client_s* stt_client_get_by_uid(const int uid)
                }
        }
 
-       SLOG(LOG_ERROR, TAG_STTC, "[ERROR] Fail to get client by uid");
+       SLOG(LOG_ERROR, TAG_STTC, "[ERROR] Fail to get client by uid"); //LCOV_EXCL_LINE
 
        return NULL;
 }