+Text not found within an archive

Bug reports will be moved here when the described bug has been fixed

Moderators: Hacker, petermad, Stefan2, white

Post Reply
Stryiker
New Member
New Member
Posts: 1
Joined: 2014-03-18, 21:47 UTC

+Text not found within an archive

Post by *Stryiker »

It looks like the feature "unpack files < 1MB to memory to speed the search up" uses the compacted size of the file instead of its actual size. To test the behaviour I created a text file with exactly 1048577 characters - simply 1024 lines with 1022 zeroes and a CR/LF each plus an "x" at the very end. Then I packed the file and searched that archive for any file containing "x" - with a negative result. The same search works good in Lister when the zipped file is viewed from within the archive, e.g. unpacked to temp.
User avatar
MVV
Power Member
Power Member
Posts: 8711
Joined: 2008-08-03, 12:51 UTC
Location: Russian Federation

Post by *MVV »

I can confirm that TC can't find 'x' in such file inside of ZIP archive (however it works inside of CAB archive).

Test archive test.zip is here (you mush get it out from outer container.zip in order to reproduce bug):

Code: Select all

MIME-Version: 1.0
Content-Type: application/octet-stream; name="container.zip"
Content-Transfer-Encoding: base64
Content-Disposition: attachment; filename="container.zip"

UEsDBBQAAgAIAMpTekSMQ1zlDAEAAHANAAAIAAAAdGVzdC56aXAL8GZmEWFgYuBgsAyuclErqprB
ycLAwMggABRhYChJLS7RS8rMe3tQkRHIZVJIt74vGKYAYo+CUTAKRhb4URIALy7agMWF2Lp23pkc
aMVFSUXJ28uGvAwMHCwb57Lo6/P/nJGweGrBSdUD/rFSDf8Z/zP/Y//D/0P+g/2D+gP/yRAgUxuK
AAXWwwUo9AZIoPm/KQPF4dHw/+B/ysOV8vD4IU9xeAAF/mczUCVgh1E6u85AlYAdRulsPeOgycCD
JJ3FMw+aDDxI0tl+tmFVUVAjnfEeGE4VBYnaDlz9vznAm5FJhAF3fwcCFKA0rPeDrAtbswcEGMG6
9FkQjaAAb1Y2kAwTEOYA6Xc8IB4AUEsBAhQAFAACAAgAylN6RIxDXOUMAQAAcA0AAAgAAAAAAAAA
AAAgAAAAAAAAAHRlc3QuemlwUEsFBgAAAAABAAEANgAAADIBAAAAAA==

BTW I can find files if I set 'Office/EPUB' search option.
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50541
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

Confirmed, thanks! When choosing Office/EPUB, TC cannot search in memory because it may have to unpack the office file too (which is a renamed ZIP).
Author of Total Commander
https://www.ghisler.com
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50541
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

This has been fixed in beta 5, please test it!
Author of Total Commander
https://www.ghisler.com
User avatar
MVV
Power Member
Power Member
Posts: 8711
Joined: 2008-08-03, 12:51 UTC
Location: Russian Federation

Post by *MVV »

Thank you, it works fine in b5!
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50541
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

Great, thanks!
Author of Total Commander
https://www.ghisler.com
Post Reply