Archived Forum Post

Index of archived forum posts

Question:

File is deleted immediately being unzipped

Jun 06 '14 at 10:21

I've created a self-extracting zip file of a SQL database export. Now when I uncompress the file I can watch the file uncompress and when it's all done (it's a 16GB file), it gets deleted! Does anyone have any idea how to stop this? Here's the log file:

command line: -log chilkat_log.txt
Created by version 14.5.0
Nov 24 2012
<?xml version="1.0" encoding="utf-8" ?>
<SfxConfig>
    <AutoTemp>0</AutoTemp>
    <DeleteAfterSetup>0</DeleteAfterSetup>
    <ShowFin>0</ShowFin>
    <ShowMain>1</ShowMain>
    <ShowProgress>1</ShowProgress>
    <WaitForSetup>1</WaitForSetup>
    <Encryption>1</Encryption>
    <KeyLength>128</KeyLength>
    <VersionCreatedBy>14.5.0</VersionCreatedBy>
    <SetupExe />
    <UnzipDir />
    <DefaultDir />
    <IconFile />
    <Cleanup>1</Cleanup>
</SfxConfig>

Log opened from internal point 2
Showing main dialog...
Password verified...
Current working directory: C:\Work\NextGen\201303_reload\test_of_exe
unzipDir = [C:\Work\NextGen\201303_reload\test_of_exe]
Check/create extract dir: [C:\Work\NextGen\201303_reload\test_of_exe]
Final unzip dir: [C:\Work\NextGen\201303_reload\test_of_exe]...
Setting CWD [C:\Work\NextGen\201303_reload\test_of_exe]
cleanup is requested...
Unzip complete...
processing undo list...
processing undo list...
Initialization finished.
Log opened from internal point 1
Closing log from WinMain.
exitCode = 0

Answer

Does the file get deleted if you disable you antivirus software? It might be a false positive.

Also it appears that you are using an old version of the library (November 2012), so you should update to the latest version and see if the problem persists.


Answer

Apparently, when the self-extracting EXE was created, "cleanup" was turned on. You can see from the log:

...
cleanup is requested...
Unzip complete...
processing undo list...
processing undo list...
...

The auto-cleanup makes sense when you want the self-extracting EXE to extract, run some sort of setup/install program, and then delete the extracted files. In your case, cleanup was requested, but there is no setup/install program. Determine how the SFX was originally created, looking for the cleanup option (which could be in the XML config, if used).