[opensuse] xdg-open inserting backslashes
I've got a problem opening some URLs using xdg-open on Leap 42.1. LXDE desktop. If I use xdg-open to try to open for example: xdg-open http://www.example.com/search.cgi?fred=wilma&barney=betty Then xdg-open rewrites the URL and asks firefox to open instead: http://www.example.com/search.cgi?fred=wilma\\&barney=betty and that fails (for my real URL). I know nada about xdg-open. Can anybody suggest why it is doing this and/or how to get it to open the URL I give it without mangling it? Cheers, Dave -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
On Thursday, 1 September 2016 10:55:04 EEST Dave Howorth wrote:
I've got a problem opening some URLs using xdg-open on Leap 42.1. LXDE desktop.
If I use xdg-open to try to open for example:
xdg-open http://www.example.com/search.cgi?fred=wilma&barney=betty
Then xdg-open rewrites the URL and asks firefox to open instead:
xdg-open "http://www.example.com/search.cgi?fred=wilma&barney=betty" works here. Perhaps you didn't quote the string?
Cheers, Dave -- Regards, Peter -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
On Thu, 01 Sep 2016 21:00:01 +0300
auxsvr
On Thursday, 1 September 2016 10:55:04 EEST Dave Howorth wrote:
I've got a problem opening some URLs using xdg-open on Leap 42.1. LXDE desktop.
If I use xdg-open to try to open for example:
xdg-open http://www.example.com/search.cgi?fred=wilma&barney=betty
Then xdg-open rewrites the URL and asks firefox to open instead:
xdg-open "http://www.example.com/search.cgi?fred=wilma&barney=betty" works here. Perhaps you didn't quote the string?
Thanks for trying. If you don't quote the URL then the ampersand is part of shell syntax and the URL is truncated at wilma (don't ask me how I know this). I used single quotes but I don't think that accounts for my problem. Are you running Leap and LXDE? Nobody understands xdg-open? I know it's only a shell script but I hate debugging shell scripts, especially undocumented ones. Cheers, Dave -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
On Thursday, 1 September 2016 22:24:49 EEST Dave Howorth wrote:
xdg-open "http://www.example.com/search.cgi?fred=wilma&barney=betty" works here. Perhaps you didn't quote the string?
I used single quotes but I don't think that accounts for my problem. Are you running Leap and LXDE?
I'm using Leap and KDE. What is the result of echo "http://www.example.com/search.cgi?fred=wilma&barney=betty" ?
Cheers, Dave -- Regards, Peter -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
On Fri, 02 Sep 2016 08:06:40 +0300
auxsvr
On Thursday, 1 September 2016 22:24:49 EEST Dave Howorth wrote:
xdg-open "http://www.example.com/search.cgi?fred=wilma&barney=betty" works here. Perhaps you didn't quote the string?
I used single quotes but I don't think that accounts for my problem. Are you running Leap and LXDE?
I'm using Leap and KDE. What is the result of echo "http://www.example.com/search.cgi?fred=wilma&barney=betty" ?
$ echo "http://www.example.com/search.cgi?fred=wilma&barney=betty" http://www.example.com/search.cgi?fred=wilma&barney=betty -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
On 2016-09-02 07:40, Dave Howorth wrote:
On Fri, 02 Sep 2016 08:06:40 +0300 auxsvr
wrote: On Thursday, 1 September 2016 22:24:49 EEST Dave Howorth wrote:
xdg-open "http://www.example.com/search.cgi?fred=wilma&barney=betty" works here. Perhaps you didn't quote the string?
I used single quotes but I don't think that accounts for my problem. Are you running Leap and LXDE?
I'm using Leap and KDE. What is the result of echo "http://www.example.com/search.cgi?fred=wilma&barney=betty" ?
$ echo "http://www.example.com/search.cgi?fred=wilma&barney=betty" http://www.example.com/search.cgi?fred=wilma&barney=betty
Hmm, it seems this problem may be specific to LXDE then. It also occurs on an Ubuntu 12.04 LTS system using LXDE. xdg-open is a shell script. The backslashes are inserted at line 636 in the function search_desktop_file(). The decision to do so is based on information from /usr/share/applications/firefox.desktop, which on line 153 has Exec=firefox %u (the firefox.desktop is from the Ubuntu system, I can't check my Leap system until this evening but I suppose it must be the same). That %u is what causes the backslashes to be inserted, but I've no idea yet why, or why that instruction is there, or what the desktop file is there for etc etc. If anybody understands how to debug this stuff, it would be very useful. Cheers, Dave -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
On 2016-09-02 11:17, Dave Howorth wrote:
On 2016-09-02 07:40, Dave Howorth wrote:
On Fri, 02 Sep 2016 08:06:40 +0300 auxsvr
wrote: On Thursday, 1 September 2016 22:24:49 EEST Dave Howorth wrote:
xdg-open "http://www.example.com/search.cgi?fred=wilma&barney=betty" works here. Perhaps you didn't quote the string?
I used single quotes but I don't think that accounts for my problem. Are you running Leap and LXDE?
I'm using Leap and KDE. What is the result of echo "http://www.example.com/search.cgi?fred=wilma&barney=betty" ?
$ echo "http://www.example.com/search.cgi?fred=wilma&barney=betty" http://www.example.com/search.cgi?fred=wilma&barney=betty
Hmm, it seems this problem may be specific to LXDE then. It also occurs on an Ubuntu 12.04 LTS system using LXDE.
xdg-open is a shell script. The backslashes are inserted at line 636 in the function search_desktop_file(). The decision to do so is based on information from /usr/share/applications/firefox.desktop, which on line 153 has Exec=firefox %u (the firefox.desktop is from the Ubuntu system, I can't check my Leap system until this evening but I suppose it must be the same).
That %u is what causes the backslashes to be inserted, but I've no idea yet why, or why that instruction is there, or what the desktop file is there for etc etc. If anybody understands how to debug this stuff, it would be very useful.
Need to qualify some more ... It only occurs on the Ubuntu system if I use the xdg-open script from the LEAP system. The xdg-open script on the Ubuntu system doesn't cause the problem. The scripts on the two machines are considerably different, but worryingly the header and copyright information on both is identical. It looks like somebody has edited xdg-open on openSUSE without updating the copyright info. How do I find out where that script came from? The version number reported by the Ubuntu script is 1.0.2, whilst that reported by openSUSE is 1.1.0 rc3. -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
On 2016-09-02 13:35, Dave Howorth wrote:
On 2016-09-02 11:17, Dave Howorth wrote:
On 2016-09-02 07:40, Dave Howorth wrote:
On Fri, 02 Sep 2016 08:06:40 +0300 auxsvr
wrote: On Thursday, 1 September 2016 22:24:49 EEST Dave Howorth wrote:
xdg-open "http://www.example.com/search.cgi?fred=wilma&barney=betty" works here. Perhaps you didn't quote the string?
I used single quotes but I don't think that accounts for my problem. Are you running Leap and LXDE?
I'm using Leap and KDE. What is the result of echo "http://www.example.com/search.cgi?fred=wilma&barney=betty" ?
$ echo "http://www.example.com/search.cgi?fred=wilma&barney=betty" http://www.example.com/search.cgi?fred=wilma&barney=betty
Hmm, it seems this problem may be specific to LXDE then. It also occurs on an Ubuntu 12.04 LTS system using LXDE.
xdg-open is a shell script. The backslashes are inserted at line 636 in the function search_desktop_file(). The decision to do so is based on information from /usr/share/applications/firefox.desktop, which on line 153 has Exec=firefox %u (the firefox.desktop is from the Ubuntu system, I can't check my Leap system until this evening but I suppose it must be the same).
That %u is what causes the backslashes to be inserted, but I've no idea yet why, or why that instruction is there, or what the desktop file is there for etc etc. If anybody understands how to debug this stuff, it would be very useful.
Need to qualify some more ...
It only occurs on the Ubuntu system if I use the xdg-open script from the LEAP system. The xdg-open script on the Ubuntu system doesn't cause the problem. The scripts on the two machines are considerably different, but worryingly the header and copyright information on both is identical. It looks like somebody has edited xdg-open on openSUSE without updating the copyright info.
How do I find out where that script came from?
The version number reported by the Ubuntu script is 1.0.2, whilst that reported by openSUSE is 1.1.0 rc3.
and looking on the XDG site, I see that the latest version is 1.1.1 and the line that inserts backslashes has been edited so it doesn't! Even version 1.1.0 was fixed by 2015-10-04 So that probably will fix my problem but ... there's loads of other changes in the new version so I might be going from the frying pan onto the fire, and very worryingly - again the copyright has not been updated, but the paragraph of licence conditions that specifically requires the paragraph to be contained in all modified versions has been DELETED. What's the politics of all this XDG/freedesktop stuff? -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
On 2016-09-01 11:55, Dave Howorth wrote:
I've got a problem opening some URLs using xdg-open on Leap 42.1. LXDE desktop.
If I use xdg-open to try to open for example:
xdg-open http://www.example.com/search.cgi?fred=wilma&barney=betty
Then xdg-open rewrites the URL and asks firefox to open instead:
I tried on Leap 42.2 beta. carlos@linux-qyxj:~> xdg-open "http://www.example.com/search.cgi?fred=wilma&barney=betty" carlos@linux-qyxj:~> After a while, Firefox opens http://www.example.com/search.cgi?fred=wilma&barney=betty -- Cheers / Saludos, Carlos E. R. (from 13.1 x86_64 "Bottle" at Telcontar)
On 2016-09-02 14:37, Carlos E. R. wrote:
On 2016-09-01 11:55, Dave Howorth wrote:
I've got a problem opening some URLs using xdg-open on Leap 42.1. LXDE desktop.
If I use xdg-open to try to open for example:
xdg-open http://www.example.com/search.cgi?fred=wilma&barney=betty
Then xdg-open rewrites the URL and asks firefox to open instead:
I tried on Leap 42.2 beta.
carlos@linux-qyxj:~> xdg-open "http://www.example.com/search.cgi?fred=wilma&barney=betty" carlos@linux-qyxj:~>
After a while, Firefox opens
https://bugzilla.opensuse.org/show_bug.cgi?id=997079 -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
participants (4)
-
auxsvr
-
Carlos E. R.
-
Dave Howorth
-
Dave Howorth