Skip to content

Commit

Permalink
Fix edge case of extracting a 0 byte sized file
Browse files Browse the repository at this point in the history
  • Loading branch information
ggnkua committed Sep 13, 2023
1 parent 01f838a commit 8b8ca47
Show file tree
Hide file tree
Showing 7 changed files with 17 additions and 7 deletions.
10 changes: 7 additions & 3 deletions dllmain.c
Original file line number Diff line number Diff line change
Expand Up @@ -1182,10 +1182,14 @@ int Process(tArchive* hArcData, int Operation, char* DestPath, char* DestName)
free(buf);
return E_EWRITE;
}
size_t wlen = fwrite(buf, len, 1, f);
if (ProcessDataProc)
size_t wlen = 1;
if (len)
{
abort = !ProcessDataProc(DestName, len);
size_t wlen = fwrite(buf, len, 1, f);
if (ProcessDataProc)
{
abort = !ProcessDataProc(DestName, len);
}
}
if (wlen != 1 || abort) {
free(buf);
Expand Down
Binary file modified install/jacknife.wcx
Binary file not shown.
Binary file modified install/jacknife.wcx64
Binary file not shown.
Binary file modified install/jacknife.zip
Binary file not shown.
Binary file modified install/jacknife_ctrlpagedownonly.zip
Binary file not shown.
7 changes: 5 additions & 2 deletions install/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,11 @@ Progress bar info during operations |✓|✓ |&c
Pre-built binaries are supplied.

### Linux/OSX
Starting with v0.05 pre-built binaries are supplied in the releases.
To build manually, use the `build_linux_mac.sh` script to build the plugin and follow the instructions below for Double Commander.
Starting with v0.05 pre-built binaries are supplied in the releases. To install, follow the instructions below for Double Commander.

There is a possibility that on OSX a message like "Cannot Be Opened Because the Developer Cannot be Verified". If that happens, the only course of action is to implicitly "trust the developer". Several guides exist on the internet about how to achieve this.

To build manually, use the `build_linux_mac.sh` script to build the plugin. Then see the Double Commander section below on how to install the plugin.

### Total Commander

Expand Down
7 changes: 5 additions & 2 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,11 @@ Progress bar info during operations |✓|✓ |&c
Pre-built binaries are supplied.

### Linux/OSX
Starting with v0.05 pre-built binaries are supplied in the releases.
To build manually, use the `build_linux_mac.sh` script to build the plugin and follow the instructions below for Double Commander.
Starting with v0.05 pre-built binaries are supplied in the releases. To install, follow the instructions below for Double Commander.

There is a possibility that on OSX a message like "Cannot Be Opened Because the Developer Cannot be Verified". If that happens, the only course of action is to implicitly "trust the developer". Several guides exist on the internet about how to achieve this.

To build manually, use the `build_linux_mac.sh` script to build the plugin. Then see the Double Commander section below on how to install the plugin.

### Total Commander

Expand Down

0 comments on commit 8b8ca47

Please sign in to comment.