From 56a54c9692d6e75cfbb368116e2350c5579f6eaa Mon Sep 17 00:00:00 2001 From: Stephen Watson Date: Mon, 13 Jul 2009 22:39:59 +0100 Subject: [PATCH] Fix bug in XDG MIME magic: if two matches at the same priority returned exactly the same type, it was considered a conflict. --- ROX-Filer/src/xdgmimemagic.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/ROX-Filer/src/xdgmimemagic.c b/ROX-Filer/src/xdgmimemagic.c index d1d04b64..82278a16 100644 --- a/ROX-Filer/src/xdgmimemagic.c +++ b/ROX-Filer/src/xdgmimemagic.c @@ -760,7 +760,10 @@ _xdg_mime_magic_lookup_data (XdgMimeMagic *mime_magic, mime_type = match->mime_type; priority = match->priority; } + /* Is this another match at same priority which is not the same + * type again, or a sub-type */ else if (had_match && match->priority == priority && mime_type && + strcmp(mime_type, match->mime_type)!=0 && !_xdg_mime_mime_type_subclass (mime_type, match->mime_type)) /* multiple unrelated patterns with the same priority matched, * so we can't tell what type this is. */ -- 2.11.4.GIT