intel/perf: break GL query stuff away
[mesa.git] / src / gallium / drivers / iris / iris_fence.h
index caf2ceeb3151442ffcededf82e0f828977c0e5b4..0ce5fa8ebfb7a0d45b35dd149d3b6afaf821d218 100644 (file)
@@ -51,7 +51,8 @@ iris_syncpt_reference(struct iris_screen *screen,
                       struct iris_syncpt **dst,
                       struct iris_syncpt *src)
 {
-   if (pipe_reference(&(*dst)->ref, &src->ref))
+   if (pipe_reference(*dst ? &(*dst)->ref : NULL,
+                      src ? &src->ref: NULL))
       iris_syncpt_destroy(screen, *dst);
 
    *dst = src;