exo-open does not handle URIs properly

Bug #1173727 reported by Henri Reinikainen on 2013-04-27
100
This bug affects 21 people
Affects Status Importance Assigned to Milestone
exo
Fix Released
High
exo (Ubuntu)
Undecided
Unassigned
xdg-utils (Ubuntu)
Undecided
Unassigned

Bug Description

when executing xdg-open "magnet:?...

xdg-open detects XFCE display manager and calls exo-open "$1" witch is not capable to handle magnets at all.

should it call gnome-open with xubuntu?

quick fix:

edit /usr/bin/xdg-open and change
if [ x"$DE" = x"" ]; then
    DE=generic
fi

to
if [ x"$DE" = x"" ]; then
    DE=generic
fi
DE=gnome

ProblemType: Bug
DistroRelease: Ubuntu 13.04
Package: xdg-utils 1.1.0~rc1-2ubuntu7
ProcVersionSignature: Ubuntu 3.8.0-19.29-generic 3.8.8
Uname: Linux 3.8.0-19-generic x86_64
NonfreeKernelModules: fglrx
ApportVersion: 2.9.2-0ubuntu8
Architecture: amd64
Date: Sat Apr 27 22:08:40 2013
InstallationDate: Installed on 2013-04-11 (16 days ago)
InstallationMedia: Xubuntu 12.04.2 LTS "Precise Pangolin" - Release amd64 (20130213)
MarkForUpload: True
PackageArchitecture: all
SourcePackage: xdg-utils
UpgradeStatus: Upgraded to raring on 2013-04-25 (1 days ago)

Henri Reinikainen (henrixd) wrote :
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in xdg-utils (Ubuntu):
status: New → Confirmed

Created attachment 5040
string: fix exo_str_looks_like_an_uri()

Commit d11199b (Check if uris also contain a slash (bug #9244)) tried to
fix a hang in thunar by properly recognizing that 'http:' is not an URI,
however, while doing so, it broke proper URIs like 'magnet:foo'.

As the RFC clearly states:

   The following are two example URIs and their component parts:

         foo://example.com:8042/over/there?name=ferret#nose
         \_/ \______________/\_________/ \_________/ \__/
          | | | | |
       scheme authority path query fragment
          | _____________________|__
         / \ / \
         urn:example:animal:ferret:nose

But even with this succinct example exo_str_looks_like_an_uri() fails.

There is an easy solution; fail only when component part is missing
('urn:'), but succeed otherwise.

This solution fixes 'magnet:foo', and doesn't break the current
expectation from thunar that 'http:' should fail, having the best of
both worlds.

[1] http://www.ietf.org/rfc/rfc3986.txt

See bugs:
https://bugzilla.xfce.org/show_bug.cgi?id=9597
https://bugzilla.xfce.org/show_bug.cgi?id=9647
https://bugzilla.xfce.org/show_bug.cgi?id=9244

In , 8-nick (8-nick) wrote :

Applied in 05848bb.

In , 8-nick (8-nick) wrote :

*** Bug 9597 has been marked as a duplicate of this bug. ***

Joonas Saarinen (jza) wrote :

Right. This makes Magnet link integration broken on Xubuntu by default.

When clicking a Magnet link on a web browser, the user is met with the error dialog "Unable to detect the URI-scheme of "magnet:..."

markusk (markuskreiner) wrote :

and obviously doesn't affect magnet links only - above mentioned fix also works for opening spotify links in the spotify app.

Tom Oehser (tom-toms) wrote :

I think exo has added support for magnet, so one solution would be to refresh that...
WHY are there so many variants of this?

Ray Walz (raypwalz) wrote :

I'm having the same problem opening a magnet link in the Google Chrome 32.0.1700.102 on Xubuntu 13.10. It's an inconvenience, but I'll just use the workaround.

lqlarry (lqlarry) wrote :

Quick fix in bug description worked for me. Google Chrome Version 38.0.2125.104 (64-bit) & Xubuntu 14.10.

Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

affects: xdg-utils (Debian) → exo (Ubuntu)
Changed in exo (Ubuntu):
status: New → Confirmed
Changed in exo (Ubuntu):
status: New → Confirmed
summary: - xdg-open calls exo-open not gnome-open
+ exo-open does not handle URIs properly
Changed in xdg-utils (Ubuntu):
status: Confirmed → Invalid
Changed in exo:
importance: Unknown → High
status: Unknown → Fix Released
Sean Davis (bluesabre) wrote :

This bug was fixed in exo 0.10.3, included in Vivid.

Changed in exo (Ubuntu):
status: Confirmed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.