Fix of issue 3534.
svn: r14447
This commit is contained in:
parent
284af59757
commit
61ae6d87ec
@ -38,6 +38,8 @@ import urlparse
|
|||||||
import gtk
|
import gtk
|
||||||
import pango
|
import pango
|
||||||
import os
|
import os
|
||||||
|
import sys
|
||||||
|
import urllib
|
||||||
import gobject
|
import gobject
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
@ -458,6 +460,7 @@ class GalleryTab(ButtonTab, DbGUIElement):
|
|||||||
protocol, site, mfile, j, k, l = urlparse.urlparse(d)
|
protocol, site, mfile, j, k, l = urlparse.urlparse(d)
|
||||||
if protocol == "file":
|
if protocol == "file":
|
||||||
name = Utils.fix_encoding(mfile)
|
name = Utils.fix_encoding(mfile)
|
||||||
|
name = unicode(urllib.url2pathname(name.encode(sys.getfilesystemencoding())))
|
||||||
mime = gen.mime.get_type(name)
|
mime = gen.mime.get_type(name)
|
||||||
if not gen.mime.is_valid_type(mime):
|
if not gen.mime.is_valid_type(mime):
|
||||||
return
|
return
|
||||||
|
Loading…
Reference in New Issue
Block a user