summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorShaun McCance <shaunm@gnome.org>2016-02-03 06:02:07 -0500
committerShaun McCance <shaunm@gnome.org>2016-02-03 06:02:07 -0500
commitf48343390362cfb50ef6614d003c3cc588d3f841 (patch)
treea6234100aee0f3f80bbaf4f1a2b5646bb5bc1479
parente5f3a147aec6aeb4629194e1d3a3eefc1d4716e9 (diff)
downloadyelp-f48343390362cfb50ef6614d003c3cc588d3f841.tar.gz
Allow .docbook files as file path, #699995
-rw-r--r--libyelp/yelp-uri.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/libyelp/yelp-uri.c b/libyelp/yelp-uri.c
index ca315641..7425f25c 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;