Fix clang error about type mismatch GtkWidget* != void* aka gpointer

in the second argument and an extra ptr level in the first.
(The declaration is
g_atomic_pointer_compare_and_exchange(void* atomic, gpointer old,
                                      gpointer new)
but that's wrong as it tests *atomic == old so atomic needs to be
void**. But we were passing &gpointer* i.e. void***.)
This commit is contained in:
John Ralls
2020-05-10 14:49:20 -07:00
parent d58f260aa9
commit 3d6a06d503
2 changed files with 4 additions and 4 deletions

View File

@@ -2256,9 +2256,9 @@ gppat_filter_response_cb (GtkWidget *dialog,
}
/* Clean up and delete dialog */
gptemp = (gpointer *)fd->dialog;
gptemp = (gpointer)fd->dialog;
g_atomic_pointer_compare_and_exchange(&gptemp,
dialog, NULL);
(gpointer)dialog, NULL);
fd->dialog = gptemp;
gtk_widget_destroy(dialog);
LEAVE("types 0x%x", fd->visible_types);

View File

@@ -1140,9 +1140,9 @@ gppot_filter_response_cb (GtkWidget *dialog,
}
/* Clean up and delete dialog */
gptemp = (gpointer *)fd->dialog;
gptemp = (gpointer)fd->dialog;
g_atomic_pointer_compare_and_exchange(&gptemp,
dialog, NULL);
(gpointer)dialog, NULL);
fd->dialog = gptemp;
gtk_widget_destroy(dialog);
LEAVE("");