Bug 492524

Summary: Eject does not handle spaces in path correctly
Product: [Fedora] Fedora Reporter: Per Inge Mathisen <per.mathisen>
Component: ejectAssignee: Zdenek Prikryl <zprikryl>
Status: CLOSED RAWHIDE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: low    
Version: 10CC: zprikryl
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2009-03-31 09:49:31 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Per Inge Mathisen 2009-03-27 09:02:12 UTC
Description of problem:
From the command-line, writing "eject /media/NAME OF DISK" does not work if the name of the disk media contains spaces. Tested on both Fedora 10 and 8.

Version-Release number of selected component (if applicable):
Eject version 2.1.5

How reproducible:
Make a CD with spaces in its name, try to eject from command-line with a path to its entry in /media instead of going after its device entry in /dev

Actual results:
[perim@localhost]$ eject -v /media/MY\ Test
eject: device name is `/media/MY Test'
eject: expanded name is `/media/MY Test'
eject: `/media/MY Test' is not mounted
eject: `/media/MY Test' is not a mount point
eject: tried to use `/media/MY Test' as device name but it is no block device
eject: unable to find or open device for: `/media/MY Test'

[perim@localhost ImageImport]$ cat /etc/mtab
...
/dev/sr1 /media/MY\040Test udf ro,nosuid,nodev,uhelper=hal,uid=500 0 0

Expected results:
CD popping out and happy user.

Additional info:
See also http://bugs.gentoo.org/151257 for a patch that might fix the problem.

Comment 1 Zdenek Prikryl 2009-03-31 09:49:31 UTC
Hi, I fixed a patch which is already in our eject. Now eject should handle spaces properly.