http://bugs.winehq.org/show_bug.cgi?id=32833
Bug #: 32833 Summary: Wine cannot find help (chm) files in dir with () in name Product: Wine Version: 1.5.22 Platform: x86-64 OS/Version: Linux Status: UNCONFIRMED Severity: normal Priority: P2 Component: -unknown AssignedTo: wine-bugs@winehq.org ReportedBy: scallegari@arces.unibo.it Classification: Unclassified
Hi,
modern programs install in wine in '.wine/drive_c/Program Files (x86)/'
However, when they put their help files here, possibly due to the () in the path, wine cannot find the help files anymore.
To reproduce:
put a .chm file in .wine/drive_c launch wine explorer navigate to C: and click on the the .chm file. It opens just fine in the hh chm viewer.
Now move the .chm file in .wine/drive_c/Program Files (x86)/ as before launch wine explorer navigate to C:Program Files (x86)/ click on the .chm file. Another instance of the wine explorer opens.
http://bugs.winehq.org/show_bug.cgi?id=32833
--- Comment #1 from Sergio Callegari scallegari@arces.unibo.it 2013-01-30 04:04:46 CST --- Let me conclude the last sentence in my report:
Another instance of the wine explorer opens at "C:Program Files". This is a sign that wine cannot see the chm file at all since the path gets truncated at the "(" char.
http://bugs.winehq.org/show_bug.cgi?id=32833
Rico kgbricola@web.de changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |NEW Ever Confirmed|0 |1
--- Comment #2 from Rico kgbricola@web.de 2013-01-30 06:06:16 CST --- I gave it a try, I could confirm the problem, but I don't think it has to do with the brackets "()", more I think it has to do something with the spaces...
Test case: mkdir ~/.wine/drive_c/a\ test wine explorer "C:\a test" -> opens "C:\a test" (ok)
echo "t1" > ~/.wine/drive_c/a\ test/1.txt wine explorer "C:\a test" -> opens "C:\a test" (ok) click on 1.txt -> opens notepad "C:\a test\1.txt" (ok) wine explorer "C:\a test\1.txt" -> opens notepad "C:\a test\1.txt" (ok) wine notepad "C:\a test\1.txt" (ok)
mkdir ~/.wine/drive_c/a wine explorer "C:\a test" -> opens "C:\a test" (ok) && click on 1.txt -> opens "C:\a" (wrong) wine explorer "C:\a test\1.txt" -> opens "C:\a" (wrong) wine explorer "C:\a" -> opens "C:\a" (ok) wine notepad "C:\a test\1.txt" (ok)
echo "t2" > ~/.wine/drive_c/a/1.txt wine explorer "C:\a test" -> opens "C:\a test" (ok) && click on 1.txt -> opens "C:\a" (wrong) wine explorer "C:\a test\1.txt" -> opens "C:\a" (wrong) wine explorer "C:\a" -> opens "C:\a" (ok) && click on 1.txt -> opens "C:\a" (ok) wine explorer "C:\a\1.txt" -> opens notepad "C:\a\1.txt" (ok) wine notepad "C:\a test\1.txt" (ok) wine notepad "C:\a\1.txt" (ok)
wine explorer "C:\invalid" -> opens "Desktop" wine explorer "C:\ " -> opens "C:" (I think this should be handled the same as above)
So when a folder with a space in it has the same prefix as one without there is something wrong, this holds true even for folders which start with an space, examples: - "a", "a test" - "Program Files", "Program Files (x86)" - "C:\ ", "C:"
Imho this may affect a couple of apps ... mostly 32bit apps in a 64bit prefix. You couldn't easily rename "Program Files (x86)" so the best workaround for now is using a 32bit prefix (WINEARCH=win32). Otherwise try to avoid using nearly the same name for folders (which differ only by a " xxx").
http://bugs.winehq.org/show_bug.cgi?id=32833
--- Comment #3 from Bruno Jesus 00cpxxx@gmail.com 2013-01-30 06:09:14 CST --- May be related to bug 23321.
http://bugs.winehq.org/show_bug.cgi?id=32833
--- Comment #4 from Sergio Callegari scallegari@arces.unibo.it 2013-01-30 07:25:00 CST --- I thought it was the "(" because the path was getting confused there. But your analysis that "Program Files" and "Program Files (x86)" share a common prefix terminated by a space shows that I was wrong. Should I change the bug title accordingly? Or is this bug going to be just closed as a duplicate of something else?
http://bugs.winehq.org/show_bug.cgi?id=32833
Sergio Callegari scallegari@arces.unibo.it changed:
What |Removed |Added ---------------------------------------------------------------------------- Summary|Wine cannot find help (chm) |Wine cannot find files (and |files in dir with () in |particularly help files) in |name |dir with spaces in name
--- Comment #5 from Sergio Callegari scallegari@arces.unibo.it 2013-02-17 07:25:03 CST --- Still present in 1.5.24.
http://bugs.winehq.org/show_bug.cgi?id=32833
Sergio Callegari scallegari@arces.unibo.it changed:
What |Removed |Added ---------------------------------------------------------------------------- Summary|Wine cannot find files (and |Wine cannot find files (and |particularly help files) in |particularly help chm |dir with spaces in name |files) in dir with spaces | |in name
--- Comment #6 from Sergio Callegari scallegari@arces.unibo.it 2013-02-17 07:27:19 CST --- Please, consider if this is really a duplicate of 23321.
Also, please consider defaulting to win32 arch until this is fixed, as this appears to completely break the help system in some applications when installed in win64 mode (that puts stuff in 'Program Files (x86)' that gets mismatched with 'Program Files'.
http://bugs.winehq.org/show_bug.cgi?id=32833
--- Comment #7 from Sergio Callegari scallegari@arces.unibo.it 2013-05-30 02:46:52 CDT --- Just a reminder. Bug still present in 1.5.31. Hurts, since it may break the help system of applications (E.g. LTSPICE, which conversely advertises wine on its web page and tries to be wine friendly).
Furthermore, I suspect that it can be exploited to forge paths with spaces in order to have users run some code when they expect to run some other.
https://bugs.winehq.org/show_bug.cgi?id=32833
Austin English austinenglish@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Resolution|--- |DUPLICATE
--- Comment #8 from Austin English austinenglish@gmail.com --- Dupe.
*** This bug has been marked as a duplicate of bug 23321 ***
https://bugs.winehq.org/show_bug.cgi?id=32833
Austin English austinenglish@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED
--- Comment #9 from Austin English austinenglish@gmail.com --- Closing.