Files containing '%' can't be indexed 2 bugs in 1: We need to escape % and If we want to pass a character such as % to gnome_vfs_get_mime_type then it wants it to be in %-encoded form (%25). Infact this function looks like it's more suited for uri:// style paths anyway. Index: Util/StringFu.cs =================================================================== RCS file: /cvs/gnome/beagle/Util/StringFu.cs,v retrieving revision 1.16 diff -u -B -p -r1.16 StringFu.cs --- Util/StringFu.cs 18 Feb 2005 22:00:04 -0000 1.16 +++ Util/StringFu.cs 6 Mar 2005 22:03:58 -0000 @@ -271,7 +271,7 @@ namespace Beagle.Util { return false; } - static char[] CharsToQuote = { ';', '?', ':', '@', '&', '=', '$', ',', '#', ' ' }; + static char[] CharsToQuote = { ';', '?', ':', '@', '&', '=', '$', ',', '#', '%', ' ' }; static public string PathToQuotedFileUri (string path) { Index: Util/gnome.cs =================================================================== RCS file: /cvs/gnome/beagle/Util/gnome.cs,v retrieving revision 1.6 diff -u -B -p -r1.6 gnome.cs --- Util/gnome.cs 14 Jan 2005 00:05:49 -0000 1.6 +++ Util/gnome.cs 6 Mar 2005 22:03:58 -0000 @@ -31,7 +31,8 @@ namespace Beagle.Util { public static string GetMimeType (string text_uri) { - string mimeType = GLib.Marshaller.PtrToStringGFree (gnome_vfs_get_mime_type (text_uri)); + string full_uri = StringFu.PathToQuotedFileUri (text_uri); + string mimeType = GLib.Marshaller.PtrToStringGFree (gnome_vfs_get_mime_type (full_uri)); return mimeType; }