Opening files via "Open as administrator" generates commandline with extra blank space

Bug #252633 reported by Siva Chandran P
34
This bug affects 1 person
Affects Status Importance Assigned to Milestone
GKSu
New
Undecided
Unassigned
gksu (Ubuntu)
Fix Released
Low
Unassigned
Hardy
Fix Released
Undecided
Unassigned
Intrepid
Won't Fix
Undecided
Unassigned
Jaunty
Fix Released
Low
Unassigned

Bug Description

Binary package hint: nautilus-gksu

Suppose if we open an archive(i.e. .tar.gz) via "Open as administrator" then it opens two file-roller window. One window says "Unable to open" and other window shows the archive content. But the first window steals focus, so we have to click "Ok" and close it to do anything with the other window.

Internally nautilus-gksu finds the application name for selected file's mime type. But the returned application name contains one extra blank space which leads to a commandline something like "appBBvfspath", where app is application name, B is a blank space and vfspath is a vfs path of the file. In my case file-roller treats the second blank space as seperate parameter and tries to open it.

This not only happens with file-roller but with lot of other applications(even with nautilus itself BUG #79110) too.

The patch I have attached strips any leading/trailing spaces from the commandline(cmd).

Revision history for this message
Siva Chandran P (siva-chandran-p) wrote :
Changed in gksu:
status: New → Confirmed
Changed in gksu:
importance: Undecided → Low
Revision history for this message
mbsullivan (mbsullivan) wrote :

I can confirm that this patch worked for me. Good work!

Revision history for this message
Ansus (neptunia) wrote :

Still in Intrepid.

Revision history for this message
Matthias Metzger (macellarius) wrote :

Yes, patch worked nicely. Thanks.
How to apply it? Watch https://wiki.ubuntu.com/UbuntuPackagingGuide/BuildFromDebdiff

Revision history for this message
Matthias Metzger (macellarius) wrote :

I created a PPA with updated debs containing the patch from Siva Chandran P.
Binary packages: gksu; nautilus-gksu
https://launchpad.net/~macellarius/+archive

Revision history for this message
Luca Falavigna (dktrkranz) wrote :

Debdiff for Jaunty.

Revision history for this message
Luca Falavigna (dktrkranz) wrote :

Debdiff for intrepid-proposed.

Revision history for this message
Luca Falavigna (dktrkranz) wrote :

Debdiff for hardy-proposed.

Revision history for this message
Martin Pitt (pitti) wrote :

This is not the corresponding upstream bug. Please forward it upstream and/or to Debian.

Changed in gksu:
importance: Unknown → Undecided
status: Unknown → New
Revision history for this message
Luca Falavigna (dktrkranz) wrote :

Patch submitted upstream: https://savannah.nongnu.org/patch/?6688.

Martin Pitt (pitti)
Changed in gksu:
importance: Undecided → Unknown
status: New → Unknown
importance: Unknown → Undecided
status: Unknown → New
Revision history for this message
Martin Pitt (pitti) wrote :

This is a noncritical bug which does not meet the SRU guidelines. I can be talked into a hardy SRU, since we are more generous there due to LTS-ness.

Changed in gksu:
status: New → Won't Fix
Revision history for this message
Martin Pitt (pitti) wrote :

Hardy fix uploaded, thank you!

Changed in gksu:
status: New → In Progress
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package gksu - 2.0.0-5ubuntu4

---------------
gksu (2.0.0-5ubuntu4) jaunty; urgency=low

  * debian/patches/21_strip_blank_space.patch:
    - Strip extra blank spaces to avoid loading an application twice when
      launched via nautilus-gksu extension, thanks to Siva Chandran for
      the patch (LP: #252633).

 -- Luca Falavigna <email address hidden> Tue, 09 Dec 2008 22:34:09 +0100

Changed in gksu:
status: Confirmed → Fix Released
Revision history for this message
Martin Pitt (pitti) wrote :

Accepted into hardy-proposed, please test and give feedback here. Please see https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Thank you in advance!

Changed in gksu:
status: In Progress → Fix Committed
Revision history for this message
Ansus (neptunia) wrote :

I use it under Intrepid and works well.

Revision history for this message
Steve Beattie (sbeattie) wrote :

I have reproduced the error under the version of nautilus-gksu in hardy-updates, 2.0.0-5ubuntu3, and have verified that the version in hardy-proposed, 2.0.0-5ubuntu3.8.04.1, fixes the issue. I verified that it works properly even in the case of a filename that begins with a space. I also verified that gksu and gksudo continued to function as expected.

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package gksu - 2.0.0-5ubuntu3.8.04.1

---------------
gksu (2.0.0-5ubuntu3.8.04.1) hardy-proposed; urgency=low

  * debian/patches/21_strip_blank_space.patch:
    - Strip extra blank spaces to avoid loading an application twice when
      launched via nautilus-gksu extension, thanks to Siva Chandran for
      the patch (LP: #252633).

 -- Luca Falavigna <email address hidden> Tue, 09 Dec 2008 22:34:09 +0100

Changed in gksu:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

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