Fix GTimeVal deprecation warning

This commit is contained in:
DanielChabrowski
2020-07-15 01:53:53 +02:00
parent 16a1a9f910
commit 5a26e83574

View File

@@ -343,13 +343,10 @@ task_list_find_for_pid (GArray *task_list, GPid pid, Task **task, guint *idx)
static glong static glong
__current_timestamp (void) __current_timestamp (void)
{ {
GTimeVal current_time; gint64 tv = g_get_real_time ();
g_get_current_time (&current_time); return tv / G_USEC_PER_SEC;
return current_time.tv_sec;
} }
XtmTaskManager * XtmTaskManager *
xtm_task_manager_new (GtkTreeModel *model) xtm_task_manager_new (GtkTreeModel *model)
{ {