Sync current time 88/183288/1 accepted/tizen/unified/20180712.092638 submit/tizen/20180711.083748
authorhyunuktak <hyunuk.tak@samsung.com>
Wed, 4 Jul 2018 06:13:27 +0000 (15:13 +0900)
committerhyunuktak <hyunuk.tak@samsung.com>
Wed, 4 Jul 2018 06:13:30 +0000 (15:13 +0900)
Change-Id: I0b741ffd37d3848a6ce01c260908e3acd8b80cf2
Signed-off-by: hyunuktak <hyunuk.tak@samsung.com>
src/monitor/stc-monitor.c

index 8ee3533..9db1cfb 100755 (executable)
@@ -1013,7 +1013,8 @@ static gboolean __update_app_statistics(gpointer key, gpointer value,
 
 static gboolean __flush_apps_stats_to_database(gpointer user_data)
 {
-       time_t current_time = time(0);
+       time_t current_time = 0;
+       time(&current_time);
 
        if (g_system->apps_tree_updated == FALSE)
                return G_SOURCE_REMOVE;
@@ -1109,7 +1110,7 @@ static void __interface_counter_update(stc_app_key_s *app_key,
                 context->counter->iftype == STC_IFACE_USB) ||
                (app_value->classid == STC_TETHERING_APP_CLASSID &&
                 context->counter->iftype == STC_IFACE_P2P))
-               __app_counter_update(app_key, app_value, context);
+                __app_counter_update(app_key, app_value, context);
 }