xdg-open does not handle multiple applications returned from xdg-mime
Submitted by Kjetil Torgrim Homme
Assigned to Portland Bugs
Description
Created attachment 129146 possible default applications are separated by semicolons
on my Fedora 24 system, xdg-mime will return a semicolon separated list (from /usr/share//applications/mimeapps.list). xdg-open will use the whole string verbatim as the name of the desktop file, and it fails.
Example:
$ /bin/xdg-mime query default image/jpeg eog.desktop; $ /bin/xdg-mime query default image/svg+xml eog.desktop;gthumb.desktop;
notice the trailing semicolon.
it seems to me xdg-open should split on ";" and look for each application in turn. I have a patch to do so at
https://github.com/kjetilho/xdg-utils/tree/open-fix
the patch is enclosed. it also fixes a trivial but critical typo in xdg-open.
Patch 129146, "possible default applications are separated by semicolons":
open-fix.patch
Version: TP