Initialize ongoing_flag and delete ongoing_flag conditional statement. 73/70573/1
authorseungha.son <seungha.son@samsung.com>
Thu, 19 May 2016 13:43:18 +0000 (22:43 +0900)
committerseungha.son <seungha.son@samsung.com>
Thu, 19 May 2016 13:45:53 +0000 (22:45 +0900)
Signed-off-by: seungha.son <seungha.son@samsung.com>
Change-Id: Ib8148f50466875edbc17c87211ad391494196c22

src/notification.c
src/notification_ipc.c

index fa31786..4931239 100755 (executable)
@@ -1595,6 +1595,7 @@ static notification_h _notification_create(notification_type_e type)
        noti->led_operation = NOTIFICATION_LED_OP_OFF;
        noti->display_applist = NOTIFICATION_DISPLAY_APP_NOTIFICATION_TRAY | NOTIFICATION_DISPLAY_APP_TICKER | NOTIFICATION_DISPLAY_APP_INDICATOR;
        noti->auto_remove = true;
+       noti->ongoing_flag = false;
 
        err_app_manager = app_manager_get_app_id(getpid(), &app_id);
        if (err_app_manager != APP_MANAGER_ERROR_NONE || app_id == NULL) {
index f412bd7..e1e035e 100755 (executable)
@@ -1425,8 +1425,7 @@ EXPORT_API GVariant *notification_ipc_make_gvariant_from_noti(notification_h not
        if (noti->tag != NULL)
                g_variant_builder_add(&builder, "{iv}", NOTIFICATION_DATA_TYPE_TAG, g_variant_new_string((const gchar *)noti->tag));
 
-       if (noti->ongoing_flag != 0)
-               g_variant_builder_add(&builder, "{iv}", NOTIFICATION_DATA_TYPE_ONGOING_FLAG, g_variant_new_int32(noti->ongoing_flag));
+       g_variant_builder_add(&builder, "{iv}", NOTIFICATION_DATA_TYPE_ONGOING_FLAG, g_variant_new_int32(noti->ongoing_flag));
 
        g_variant_builder_add(&builder, "{iv}", NOTIFICATION_DATA_TYPE_AUTO_REMOVE, g_variant_new_int32(noti->auto_remove));