Bug 151621
Summary: | RPMs fail to install with spaces in the directory name | ||
---|---|---|---|
Product: | [Fedora] Fedora | Reporter: | James Hall <rio> |
Component: | system-config-packages | Assignee: | Jeremy Katz <katzj> |
Status: | CLOSED RAWHIDE | QA Contact: | |
Severity: | medium | Docs Contact: | |
Priority: | medium | ||
Version: | 4 | CC: | ejhuff, felipe.contreras, mporta, roessler |
Target Milestone: | --- | Keywords: | EasyFix |
Target Release: | --- | ||
Hardware: | i386 | ||
OS: | Linux | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | Bug Fix | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2006-02-06 21:58:39 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
James Hall
2005-03-20 23:31:55 UTC
tried it out and can confirm that. Executing the following command as root user and non-privalidged user has the following effect: 1. Open Terminal 2. type "system-install-packages /home/rio/My\ Downloads/AdobeReader_enu-7.0.0-1.i386.rpm" 3. Produces the error described above 4. su - 5. type "system-install-packages /home/rio/My\ Downloads/AdobeReader_enu-7.0.0-1.i386.rpm" 6. Behaves as expected Therefore I imagine it could be a problem with the way system-auth passes arguments. Will do more testing soon. *** Bug 76936 has been marked as a duplicate of this bug. *** I can reproduce this bug. The fix is to change /usr/sbin/system-install-packages, instead of sending $* we should send "$@". system-config-packages seems to have this problem too and probably some others. However rpm still doesn't handle paths with spaces. Problem still present in FC4 Reassigning to package owner. *** Bug 163416 has been marked as a duplicate of this bug. *** *** Bug 176311 has been marked as a duplicate of this bug. *** I don't get it, I already told you the fix, why don't you fix it? It is the right way to do it, if you don't believe me you can check the bash manual; we want "$@". * Expands to the positional parameters, starting from one. When the expansion occurs within double quotes, it expands to a single word with the value of each parameter separated by the first character of the IFS special variable. That is, "$*" is equivalent to "$1c$2c...", where c is the first character of the value of the IFS variable. If IFS is unset, the parameters are separated by spaces. If IFS is null, the parameters are joined without intervening separators. @ Expands to the positional parameters, starting from one. When the expansion occurs within double quotes, each parameter expands to a separate word. That is, "$@" is equivalent to "$1" "$2" ... When there are no positional parameters, "$@" and $@ expand to nothing (i.e., they are removed). Felipe Contreras, Looks like the package owner doesn't have enough time to sort this out, so if you could post a patch that would be great. I'd love to see this easily fixable bug I reported 9 months ago get wrapped up. I really don't see why a patch is needed.... Here is what /usr/sbin/system-install-packages looks like: exec python /usr/share/system-config-packages/SinglePackageWindow.py $* Here is what it should look like: exec python /usr/share/system-config-packages/SinglePackageWindow.py "$@" There is only one line in the file The Patch of: Felipe Contreras works in this case There is also one more thing I noted while trying this out: RPM will not accept files with spaces in the path like so: rpm -Uvh /home/tejas/My\ Downloads/gobby-0.2.2-6.fc4.i386.rpm as other programs do. However, rpm WILL accept the rpm if the \ is ALSO escaped. Hense, rpm WILL install the package like this: rpm -Uvh /home/tejas/My\\\ Downloads/gobby-0.2.2-6.fc4.i386.rpm I don't think this should be patched here, however, and I'll post this up as an RPM bug as well Yes, there are two bugs, one is system-install-packages not handling spaces, and another is rpm not handling spaces well. I purposed a fix for system-install-packages, probably that is the way we should be doing it, and the same thing happens for other scripts. However the fix for rpm is something else. This should be handled better in the system-install-packages from pirut. |