Fix a compiler warning
authorMatthias Clasen <mclasen@redhat.com>
Fri, 13 Jan 2023 16:41:49 +0000 (11:41 -0500)
committerMatthias Clasen <mclasen@redhat.com>
Fri, 13 Jan 2023 17:07:40 +0000 (12:07 -0500)
Clang things that timings can be NULL here,
and I think it might be right.

gdk/gdkframeclockidle.c

index 8df1918a00b01381418bbb853f460faf1edff501..b3e07f86aba77c1d14e6280db9e61628ce06b6f2 100644 (file)
@@ -622,7 +622,10 @@ gdk_frame_clock_paint_idle (void *data)
             }
 #ifdef G_ENABLE_DEBUG
             if (GDK_DEBUG_CHECK (FRAMES))
-              timings->frame_end_time = g_get_monotonic_time ();
+              {
+                if (timings)
+                  timings->frame_end_time = g_get_monotonic_time ();
+              }
 #endif /* G_ENABLE_DEBUG */
           G_GNUC_FALLTHROUGH;