Skip to content

lz4 decompression error #446

Closed
Closed

Description

@shikharish

Running lz4 decompress fails:

2025-01-02 01:07:41 DEBUG main.c:839 Management 16: {
  "Header": {
    "ClientVersion": "0.16.0",
    "Command": 16,
    "Compression": 2,
    "Encryption": 0,
    "Output": 0,
    "Timestamp": "20250102010741"
  },
  "Request": {
    "SourceFile": "infile.lz4"
  }
}
2025-01-02 01:07:41 ERROR lz4_compression.c:629 lz4_decompression from file compression bytes < sizeof(int)
2025-01-02 01:07:41 ERROR lz4_compression.c:421 LZ4: Could not decompress infile.lz4
2025-01-02 01:07:41 ERROR lz4_compression.c:371 LZ4: Error lz4 infile.lz4

Activity

  1. added
    bug
    on Jan 1, 2025
  2. shikharish commented on Jan 1, 2025

    @shikharish
    CollaboratorAuthor

    It is a small fix, I will make a patch.

  3. added 2 commits that reference this issue on Jan 1, 2025
  4. jesperpedersen commented on Jan 1, 2025

    @jesperpedersen
    Member

    Does the file exists ? Or does it also fail with a file that doesn't exists ?

    Do we need a new error code for this ?

  5. shikharish commented on Jan 1, 2025

    @shikharish
    CollaboratorAuthor

    The error in the logic is how we are breaking out of the loop...

    I think the PR will make it more clear..If the read bytes is zero, means EOF and we break, else if it is less than expected number of bytes, than goto error.

  6. added a commit that references this issue on Jan 2, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

bug

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions