7.02a expand rar to folder with blanks and - causes errormsg
Moderators: Hacker, petermad, Stefan2, white
7.02a expand rar to folder with blanks and - causes errormsg
I just tried to extract a rar file named "e:\input\lalala lululul - mumumu mamama.rar" to "e:\test\lalala lululul - mumumu mamama". When I start with alt+f9 I get an error from Winrar "unknown option" or similar.
The problem is that TC does not quote the target dir, so this command is executed:
"D:\Program Files\WinRAR\WinRAR.exe" x "e:\input\lalala lululul - mumumu mamama.rar" e:\test\lalala lululul - mumumu mamama *.*
I think the correct command would be:
"D:\Program Files\WinRAR\WinRAR.exe" x "e:\input\lalala lululul - mumumu mamama.rar" "e:\test\lalala lululul - mumumu mamama" *.*
the error message is probably the "-" from the target dir, where winrar doesnt know what it means.
Surprisingly everything works, even with the bogus command line.
The problem is that TC does not quote the target dir, so this command is executed:
"D:\Program Files\WinRAR\WinRAR.exe" x "e:\input\lalala lululul - mumumu mamama.rar" e:\test\lalala lululul - mumumu mamama *.*
I think the correct command would be:
"D:\Program Files\WinRAR\WinRAR.exe" x "e:\input\lalala lululul - mumumu mamama.rar" "e:\test\lalala lululul - mumumu mamama" *.*
the error message is probably the "-" from the target dir, where winrar doesnt know what it means.
Surprisingly everything works, even with the bogus command line.
NOT confirmed. Everything works fine here, Win2k SP4, TC7.02a, WinRAR 3.62.
In TC's options as path to RAR-packer I use WinRAR.exe (NOT rar.exe).
Besides that: don't you have the option "Use internal un-RAR if possible" checked? This also runs without problems here.
Some analysis:
The parameters passed to WinRAR are (according to Flint's testRAR.exe, download link see in this post):
So a short 8.3 name is used for the target dir here automatically, even using a fresh TC INI-file (with only path to WinRAR set).
In TC's options as path to RAR-packer I use WinRAR.exe (NOT rar.exe).
Besides that: don't you have the option "Use internal un-RAR if possible" checked? This also runs without problems here.
Some analysis:
The parameters passed to WinRAR are (according to Flint's testRAR.exe, download link see in this post):
Code: Select all
NEW RUN!
--------
argv[0] == 'D:\path\testRAR.exe'
argv[1] == 'x'
argv[2] == 'E:\input\lalala lululul - mumumu mamama.rar'
argv[3] == 'E:\test\LALALA~1'
argv[4] == '*.*'
Who the hell is General Failure, and why is he reading my disk?
-- TC starter menu: Fast yet descriptive command access!
-- TC starter menu: Fast yet descriptive command access!
- ghisler(Author)
- Site Admin
- Posts: 50390
- Joined: 2003-02-04, 09:46 UTC
- Location: Switzerland
- Contact:
Yes, it must be the minus sign - WinRAR probably interprets it as the start of a switch (command line options).
Author of Total Commander
https://www.ghisler.com
https://www.ghisler.com
2ghisler(Author)
Hm, indirectly the minus sign, if this really was the command line:Yes, it must be the minus sign - WinRAR probably interprets it as the start of a switch (command line options).
Tested in command line:xrmb wrote:The problem is that TC does not quote the target dir, so this command is executed:
"D:\Program Files\WinRAR\WinRAR.exe" x "e:\input\lalala lululul - mumumu mamama.rar" e:\test\lalala lululul - mumumu mamama *.*
- d:\path\WinRAR\WinRAR.exe x "e:\input\lalala lululul - mumumu mamama.rar" "E:\test\lalala lululul - mumumu mamama"
Who the hell is General Failure, and why is he reading my disk?
-- TC starter menu: Fast yet descriptive command access!
-- TC starter menu: Fast yet descriptive command access!
ok, I seem to be pretty unlucky with my last two bug reports
Let me see if I can show you the problem.
It seems to be even more tricky.
1. Win2k Server, SP2
2. Create 8.3 Filenames disabled on NTFS drives (thats key, dont know how I did that
3. use internal rar if possible checked, I'm using winrar.exe to expand as backup
4. the rar itself is a multi file rar .part1.rar, .part2.rar
for 2:
D:\my downloads>dir /x
Volume in drive D is workspace
Volume Serial Number is 30F3-1596
Directory of D:\my downloads
09/20/2007 10:12 AM <DIR> .
09/20/2007 10:12 AM <DIR> ..
08/16/2007 09:21 PM 16,609,480 ActivePerl-5.8.8.822-MSWin32-x86-280952.msi
04/18/2007 06:53 PM 1,274,079 awstats-6.6.zip
as you can see, no short names...
while one another PC with NTFS:
E:\1\a b - c d>dir /x
Volume in drive E is STUFF
Volume Serial Number is A0F8-925D
Directory of E:\1\a b - c d
09/20/2007 19:51 <DIR> .
09/20/2007 19:51 <DIR> ..
07/10/2007 18:04 79,794 AB-CD~1.PDF a b - c d.pdf
video coming next

It seems to be even more tricky.
1. Win2k Server, SP2
2. Create 8.3 Filenames disabled on NTFS drives (thats key, dont know how I did that

3. use internal rar if possible checked, I'm using winrar.exe to expand as backup
4. the rar itself is a multi file rar .part1.rar, .part2.rar
for 2:
D:\my downloads>dir /x
Volume in drive D is workspace
Volume Serial Number is 30F3-1596
Directory of D:\my downloads
09/20/2007 10:12 AM <DIR> .
09/20/2007 10:12 AM <DIR> ..
08/16/2007 09:21 PM 16,609,480 ActivePerl-5.8.8.822-MSWin32-x86-280952.msi
04/18/2007 06:53 PM 1,274,079 awstats-6.6.zip
as you can see, no short names...
while one another PC with NTFS:
E:\1\a b - c d>dir /x
Volume in drive E is STUFF
Volume Serial Number is A0F8-925D
Directory of E:\1\a b - c d
09/20/2007 19:51 <DIR> .
09/20/2007 19:51 <DIR> ..
07/10/2007 18:04 79,794 AB-CD~1.PDF a b - c d.pdf
video coming next

I was born with Norton Commander, grew up with DCC, after school I played with Windows Commander, graduated, married and had kids with Total Commander and will die using whatever its called then Commander.
ok, and here is the video you all have been waiting for:
http://home.comcast.net/~xrmb/files/tc_bug_winrardir.avi
How to Disable the 8.3 Name Creation on NTFS Partitions
http://support.microsoft.com/kb/121007
this has to be done before the target folder is created.
http://home.comcast.net/~xrmb/files/tc_bug_winrardir.avi
How to Disable the 8.3 Name Creation on NTFS Partitions
http://support.microsoft.com/kb/121007
this has to be done before the target folder is created.
2xrmb
The video can't be displayed on my current PC, I'll try on another later.
Maybe cou could apply a run of testRAR.exe in the meantime (as written above): download link is in this post
How it works:
The video can't be displayed on my current PC, I'll try on another later.
Maybe cou could apply a run of testRAR.exe in the meantime (as written above): download link is in this post
How it works:
- - copy testRAR.exe into Winrar-directory
- in TC change the path to WinRAR.exe into testRAR.exe
- perform the action you want to test
Who the hell is General Failure, and why is he reading my disk?
-- TC starter menu: Fast yet descriptive command access!
-- TC starter menu: Fast yet descriptive command access!
The video is a xvid at 1280x1024, just downloaded it and watched in Media Player Classic
here the log:
NEW RUN!
--------
argv[0] == 'D:\Program Files\WinRAR\test.exe'
argv[1] == 'x'
argv[2] == 'D:\my downloads\test.rar'
argv[3] == 'D:\MYDOWN~1\a'
argv[4] == '-'
argv[5] == 'b'
argv[6] == '*.*'
you can see that "D:\my downloads\a - b" only has a 8.3 name for my downloads, the "a - b" doesnt have one... I think thats where the problem is, and why I'm probably the first one with the problem... who has 8.3 names disabled?
here the log:
NEW RUN!
--------
argv[0] == 'D:\Program Files\WinRAR\test.exe'
argv[1] == 'x'
argv[2] == 'D:\my downloads\test.rar'
argv[3] == 'D:\MYDOWN~1\a'
argv[4] == '-'
argv[5] == 'b'
argv[6] == '*.*'
you can see that "D:\my downloads\a - b" only has a 8.3 name for my downloads, the "a - b" doesnt have one... I think thats where the problem is, and why I'm probably the first one with the problem... who has 8.3 names disabled?
I was born with Norton Commander, grew up with DCC, after school I played with Windows Commander, graduated, married and had kids with Total Commander and will die using whatever its called then Commander.
Maybe this doesn't help in this case but anyway:
Switch -- - stop switches scanning
--------------------------------------------------------------------------------
This switch tells to WinRAR that there are no more switches in the command line. It could be useful, if either archive or file name starts from '-' character. Without '--' switch such a name would be treated as a switch.
Example
add all files from the current folder to the solid archive -StrangeName
WinRAR a -s -- -StrangeName
Switch -- - stop switches scanning
--------------------------------------------------------------------------------
This switch tells to WinRAR that there are no more switches in the command line. It could be useful, if either archive or file name starts from '-' character. Without '--' switch such a name would be treated as a switch.
Example
add all files from the current folder to the solid archive -StrangeName
WinRAR a -s -- -StrangeName
it would be enough to put the target directory in quotes, so it becomes one argument. Its done for the input file, why not for the output/target?
I was born with Norton Commander, grew up with DCC, after school I played with Windows Commander, graduated, married and had kids with Total Commander and will die using whatever its called then Commander.
2xrmb
Your error and result looks very similar to what I get here, if I call it without quotes manually...

I wonder what TC would pass to WinRAR for a longer LFN having no 8.3 alternative (maybe the long file name, cut after 8 characters?)...
So I'd vote for letting TC add quotes...
It's maybe a missing plugin/codec here. I could watch most of it using VLC media player now.watched in Media Player Classic
Your error and result looks very similar to what I get here, if I call it without quotes manually...
Indeed, even MS does "not recommend" this, IIRC...you can see that "D:\my downloads\a - b" only has a 8.3 name for my downloads, the "a - b" doesnt have one... I think thats where the problem is, and why I'm probably the first one with the problem... who has 8.3 names disabled?

I wonder what TC would pass to WinRAR for a longer LFN having no 8.3 alternative (maybe the long file name, cut after 8 characters?)...
Agree and tested: this should work and do no harm. Even when using the alternative short name of the target, it also works with quotes (here on Win2k SP4, WinRAR 3.62).it would be enough to put the target directory in quotes

Who the hell is General Failure, and why is he reading my disk?
-- TC starter menu: Fast yet descriptive command access!
-- TC starter menu: Fast yet descriptive command access!
I think TC is pretty smart already (thats no news), it tries to send the short/8.3 path to Winrar, since it should behave the same way, but saves many characters which could be helpful for long command lines.
It looks that if no short path can be found the long path is send (smart), but I guess Christian assumes that for each long path there is a short path, and blanks are not valid in 8.3 short names.
So I'd vote for letting TC add quotes... Me too, me too, so I can be the only person on the planet that has 8.3 disabled
It looks that if no short path can be found the long path is send (smart), but I guess Christian assumes that for each long path there is a short path, and blanks are not valid in 8.3 short names.
So I'd vote for letting TC add quotes... Me too, me too, so I can be the only person on the planet that has 8.3 disabled

I was born with Norton Commander, grew up with DCC, after school I played with Windows Commander, graduated, married and had kids with Total Commander and will die using whatever its called then Commander.
- ghisler(Author)
- Site Admin
- Posts: 50390
- Joined: 2003-02-04, 09:46 UTC
- Location: Switzerland
- Contact:
Ah, that's the point! TC indeed tries to pass the short DOS target path to WinRAR to avoid that the command line becomes too long, and to avoid problems with spaces, but this fails because short names are turned off.Create 8.3 Filenames disabled on NTFS drives
I really cannot recommend turning off the 8.3 names. They don't cost much performance and disk space, but are needed by TC in many places...
Author of Total Commander
https://www.ghisler.com
https://www.ghisler.com
Yes I turned it back on, rebooted, works fine... maybe something for the future to remember, there might be a time when short filenames are gone... in 20 years or so 

I was born with Norton Commander, grew up with DCC, after school I played with Windows Commander, graduated, married and had kids with Total Commander and will die using whatever its called then Commander.
Fixed in 7.03.
Flint's Homepage: Full TC Russification Package, VirtualDisk, NTFS Links, NoClose Replacer, and other stuff!
Using TC 11.03 / Win10 x64
Using TC 11.03 / Win10 x64