[yelp] Allow .docbook files as file path, #699995



commit f48343390362cfb50ef6614d003c3cc588d3f841
Author: Shaun McCance <shaunm gnome org>
Date:   Wed Feb 3 06:02:07 2016 -0500

    Allow .docbook files as file path, #699995

 libyelp/yelp-uri.c |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)
---
diff --git a/libyelp/yelp-uri.c b/libyelp/yelp-uri.c
index ca31564..7425f25 100644
--- a/libyelp/yelp-uri.c
+++ b/libyelp/yelp-uri.c
@@ -1437,8 +1437,9 @@ resolve_gfile (YelpUri *uri, const gchar *query, const gchar *hash)
                 g_object_unref (old);
             }
             else if (g_str_equal (mime_type, "text/xml") ||
-                g_str_equal (mime_type, "application/docbook+xml") ||
-                g_str_equal (mime_type, "application/xml")) {
+                     g_str_equal (mime_type, "application/docbook+xml") ||
+                     g_str_equal (mime_type, "application/xml") ||
+                     g_str_has_suffix (basename, ".docbook")) {
                 char *path;
 
                 priv->tmptype = YELP_URI_DOCUMENT_TYPE_DOCBOOK;


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]