Bug 35696 - [PATCH] open_generic in xdg-open fails for filenames containing a ':' in the CWD
Summary: [PATCH] open_generic in xdg-open fails for filenames containing a ':' in the CWD
Status: NEW
Alias: None
Product: Portland
Classification: Unclassified
Component: xdg-utils (show other bugs)
Version: unspecified
Hardware: Other All
: medium normal
Assignee: Portland Bugs
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-03-26 08:19 UTC by raboof
Modified: 2011-05-13 01:40 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description raboof 2011-03-26 08:19:17 UTC
open_generic in xdg-open checks whether the argument is a file (rather than a URI) with:

    if (echo "$1" | grep -q '^file://' ||
        ! echo "$1" | egrep -q '^[a-zA-Z+\.\-]+:'); then

This fails when the file is in the CWD and called something like 'foo:bar.png'. 

A more reliable check would be:

    if (echo "$1" | grep -q '^file://' ||
        test -e "$1"); then


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.