diff options
author | Matthias Clasen <mclasen@redhat.com> | 2014-06-07 14:03:45 -0400 |
---|---|---|
committer | Matthias Clasen <mclasen@redhat.com> | 2014-06-09 13:30:53 -0400 |
commit | ed28a71bf287165a3c48e331876a22876c5f59d9 (patch) | |
tree | 7c4c1f470af1f2f4f9f2db126f06a291ec80ea2e /gtk/gtkappchooserbutton.c | |
parent | 5727a8676009532567aebc7d9b9fd617772996a8 (diff) | |
download | gtk+-ed28a71bf287165a3c48e331876a22876c5f59d9.tar.gz |
GtkAppChooserButton: Fix a possible crash
We were not correctly dealing with content_type being NULL
in one place.
Diffstat (limited to 'gtk/gtkappchooserbutton.c')
-rw-r--r-- | gtk/gtkappchooserbutton.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/gtk/gtkappchooserbutton.c b/gtk/gtkappchooserbutton.c index 9bdcf8b79a..af910c8d01 100644 --- a/gtk/gtkappchooserbutton.c +++ b/gtk/gtkappchooserbutton.c @@ -332,7 +332,8 @@ gtk_app_chooser_button_populate (GtkAppChooserButton *self) if (self->priv->show_default_item) { - default_app = g_app_info_get_default_for_type (self->priv->content_type, FALSE); + if (self->priv->content_type) + default_app = g_app_info_get_default_for_type (self->priv->content_type, FALSE); if (default_app != NULL) { |