]> spindle.queued.net Git - midori/commitdiff
Use an unknown content type if GIO fails to determine the type
authorChristian Dywan <christian@twotoasts.de>
Fri, 20 Nov 2009 00:34:16 +0000 (01:34 +0100)
committerChristian Dywan <christian@twotoasts.de>
Fri, 20 Nov 2009 00:34:16 +0000 (01:34 +0100)
midori/midori-view.c

index 1fd8416d0b3af1b42899e7e951ef7eab5b972a29..9a9f705976fc3d4b2f7ae85c6523e453a1397c34 100644 (file)
@@ -2163,6 +2163,12 @@ webkit_web_view_mime_type_decision_cb (GtkWidget*               web_view,
     #else
     content_type = g_strdup (mime_type);
     #endif
+    if (!content_type)
+    #ifdef G_OS_WIN32
+        content_type = g_content_type_get_mime_type ("*");
+    #else
+        content_type = g_strdup ("application/octet-stream");
+    #endif
     description = g_content_type_get_description (content_type);
     #if GTK_CHECK_VERSION (2, 14, 0)
     icon = g_content_type_get_icon (content_type);