[gnome-shell] shell: Replace another GTimeVal



commit a030c546618505a79d1814f0ebae79902b311ed8
Author: Florian Müllner <fmuellner gnome org>
Date:   Tue Sep 10 04:40:15 2019 +0200

    shell: Replace another GTimeVal
    
    This slipped through in commit 9b7f228f8ef.
    
    https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/709

 src/shell-util.c | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)
---
diff --git a/src/shell-util.c b/src/shell-util.c
index d38c5ab98e..3f57ada8d5 100644
--- a/src/shell-util.c
+++ b/src/shell-util.c
@@ -144,13 +144,9 @@ shell_util_format_date (const char *format,
                         gint64      time_ms)
 {
   GDateTime *datetime;
-  GTimeVal tv;
   char *result;
 
-  tv.tv_sec = time_ms / 1000;
-  tv.tv_usec = (time_ms % 1000) * 1000;
-
-  datetime = g_date_time_new_from_timeval_local (&tv);
+  datetime = g_date_time_new_from_unix_local (time_ms / 1000);
   if (!datetime) /* time_ms is out of range of GDateTime */
     return g_strdup ("");
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]