Commit Graph

95 Commits

Author SHA1 Message Date
Yann Collet
18b293d9fd updated documentation in anticipation for v1.9.4 release 2022-08-11 14:06:30 -07:00
Dominique Pelle
3347485307 fix: various typos 2022-07-31 17:47:00 +02:00
Yann Collet
6c8508323a updated LZ4 Block Format documentation
hopefully answering concerns expressed in #792
2022-07-31 14:38:45 +02:00
Yann Collet
7deae4bd22 minor : proper interface for LZ4F_getBlockSize()
and proper documentation.
Also : updated manual
2022-07-13 15:55:56 +02:00
Yann Collet
0b0e3330bc minor frame format clarification
no need to specify that a decoder can "ignore the checksum".
2022-07-10 15:25:43 -07:00
Alexander Mohr
0ac3c74de1
review: fix findings
* replace assert with test for LZ4F_uncompressedUpdate
* update documentation to incldue correct docstring
* remove unecessary entry point
* remove compress_linked_block_mode from fuzzing test

Signed-off-by: Alexander Mohr <alexander.m.mohr@mercedes-benz.com>
2022-07-05 21:14:34 +02:00
Alexander Mohr
42eb47d42f
uncompressed-api: allow uncompressed_update only for independent blocks
Signed-off-by: Alexander Mohr <alexander.m.mohr@mercedes-benz.com>
2022-07-05 11:56:23 +02:00
Alexander Mohr
9a42a9db94 dict-size: make lz4 context const
change the context to const to make
clear that the context is not modified
2022-06-11 23:58:03 +02:00
Alexander Mohr
5c7382798e
review: Fix review findings
This commit fixes the review findings

Signed-off-by: Alexander Mohr <alexander.m.mohr@mercedes-benz.com>
2022-06-10 06:37:57 +00:00
Alexander Mohr
62f6cef564
review: Fix review findings
This commit fixes the review findings

Signed-off-by: Alexander Mohr <alexander.m.mohr@mercedes-benz.com>
2022-06-10 06:00:38 +00:00
Alexander Mohr
4aeb5020c3
frame-api: add method to insert uncomressed data
new method `uncompressed_update` allows to insert blocks without
compression into the lz4 stream.
The usage is documented in the frameCompress example

Signed-off-by: Alexander Mohr <alexander.m.mohr@mercedes-benz.com>
2022-06-09 17:08:01 +02:00
Yann Collet
ce8ee024b2 update library version to v1.9.4
to reduce confusion in traces between dev branch and latest v1.9.3 release.
2022-04-17 10:06:18 -07:00
Yann Collet
1da033e601 updated block format documentation
to specifically call attention to offset==0 scenario,
which is invalid, and could lead to some form of security issue
if incorrectly dealt with (ignored).
2022-02-01 23:59:40 -08:00
Frank Wessels
775758cbb1
Update lz4_Block_format.md
Mini typo
2021-10-24 20:15:39 -07:00
Yann Collet
e2009622dd
Merge pull request #1022 from lz4/uname
make UNAME externally definable
2021-09-20 16:04:07 -07:00
a1346054
eb23590d13 fix spelling 2021-08-21 20:50:38 +00:00
Yann Collet
596c747211 make UNAME externally definable
on top of providing a central definition place, which eases maintenance,
it might also help for #1021.

Also : updated doc
2021-08-16 16:43:17 -07:00
Yann Collet
87a80acbe7 updated license & header dates 2020-11-25 14:45:14 -08:00
Yann Collet
0760724577 update doc 2020-11-15 01:31:09 -08:00
Yann Collet
be634559e3 update obsolete section documentation
and update manuals.
fix #712
2020-11-08 12:54:59 -08:00
Yann Collet
293713a4fa bump version number
to v1.9.3
2020-09-29 14:27:39 -07:00
Yann Collet
5ab7d22fa5 clarify endMark definition 2020-08-14 15:03:03 -07:00
Yann Collet
e9cfa49d0d Clarifies and fix EndMark
EndMark, the 4-bytes value indicating the end of frame,
must be `0x00000000`.

Previously, it was just mentioned as a `0-size` block.
But such definition could encompass uncompressed blocks of size 0,
with a header of value `0x80000000`.

But the intention was to also support uncompressed empty blocks.
They could be used as a keep-alive signal.
Note that compressed empty blocks are already supported,
it's just that they have a size 1 instead of 0 (for the `0` token).

Unfortunately, the decoder implementation was also wrong,
and would also interpret a `0x80000000` block header as an endMark.

This issue evaded detection so far simply because
this situation never happens, as LZ4Frame always issues
a clean 0x00000000 value as a endMark.
It also does not flush empty blocks.

This is fixed in this PR.
The decoder can now deal with empty uncompressed blocks,
and do not confuse them with EndMark.
The specification is also clarified.
Finally, FrameTest is updated to randomly insert empty blocks during fuzzing.
2020-08-12 17:27:33 -07:00
Yann Collet
bb5c34a875 bumped version number to v1.9.2
to reduce risks that future bug reports in `dev` branch report `v1.9.1` as the failing version.
2019-07-01 09:01:43 -07:00
Yann Collet
1d759576b9 precise again that LZ4 decoder needs metadata
and that such metadata must be provided / sent / saved by the application.
2019-06-06 13:20:30 -07:00
Yann Collet
5997e139f5 added more details for in-place documentation 2019-05-31 11:56:59 -07:00
Yann Collet
2f9d1736fb updated API manual 2019-05-30 16:23:53 -07:00
Yann Collet
22adbb176a add more doc on in-place (de)compression 2019-05-30 09:45:21 -07:00
Yann Collet
b17f578a91 added comments and macros for in-place (de)compression 2019-05-29 12:06:13 -07:00
Yann Collet
7a4e3b1fac bumped version number
to v1.9.1
2019-04-19 11:59:49 -07:00
Yann Collet
0b876db6d4 address a few minor Visual warnings
and created target cxx17build
2019-04-18 16:07:16 -07:00
Yann Collet
21ff1a839a updated doc to underline difference between block and frame
as this is a very frequent source of confusion for new users.
2019-04-12 11:27:44 -07:00
Yann Collet
bcb26565a7 improved documentation for LZ4 dictionary compression 2019-04-11 15:20:46 -07:00
Yann Collet
8d76c8a44a introduce LZ4_DISTANCE_MAX build macro
make it possible to generate LZ4-compressed block
with a controlled maximum offset (necessarily <= 65535).

This could be useful for compatibility with decoders
using a very limited memory budget (<64 KB).

Answer #154
2019-04-11 14:15:33 -07:00
Yann Collet
013fee5665 updated block format with more details on MF_LIMIT
aka distance from end of block for the last match.
2019-04-11 13:55:35 -07:00
Yann Collet
14c71dfa9c modified LZ4_initStreamHC() to look like LZ4_initStream()
it is now a pure initializer, for statically allocated states.
It can initialize any memory area, and because of this, requires size.
2019-04-09 13:55:42 -07:00
Yann Collet
2ece0d8380 created LZ4_initStream()
- promoted LZ4_resetStream_fast() to stable
- moved LZ4_resetStream() into deprecate, but without triggering a compiler warning
- update all sources to no longer rely on LZ4_resetStream()

note : LZ4_initStream() proposal is slightly different :
it's able to initialize any buffer, provided that it's large enough.
To this end, it accepts a void*, and returns an LZ4_stream_t*.
2019-04-05 12:56:26 -07:00
Yann Collet
7a39fb8fb6 make _fast*() decoder generate a deprecation warning
updated modification
2019-04-04 12:47:36 -07:00
Yann Collet
50f01d881d fixed doc
and bumped version number fo v1.9.0
2019-04-03 14:27:21 -07:00
Yann Collet
25da6cc967 moved _destSize() into "stable API" status
as requested in #642
2019-04-03 14:18:00 -07:00
Yann Collet
ec735ac53e updated frame format
re-wording non-full blocks,
for clarity.
2019-01-02 15:02:22 -08:00
Yann Collet
7a4e04e6a6 updated LZ4 block format
rewording the end of block conditions
for clarity and answering related questions.
2019-01-02 14:36:12 -08:00
Bing Xu
b4efd20ac8 Merge remote-tracking branch 'upstream/master' into bootcamp 2018-11-26 11:12:49 -08:00
Niklas Hambüchen
ca45db8d4f
lz4_Frame_format.md: Fix typo HexaBytes -> Exabytes 2018-11-24 22:13:10 +01:00
Yann Collet
bf9bf80f8d updated code documentation
to clarify #589
2018-10-15 11:14:30 -07:00
Yann Collet
c4c19c74b8 changed LZ4_streamDecode member order
to reduce memory usage on 128-bits systems
2018-09-25 14:43:19 -07:00
Yann Collet
dea044a485
Merge pull request #575 from lz4/apiDoc
unpublish static-only functions
2018-09-17 17:06:34 -07:00
Yann Collet
a803230f67 unpublish static-only function
these functions are now unpublished in dll by default.
One needs to opt-in, using macro LZ4_PUBLISH_STATIC_FUNCTIONS.

used this opportunity to update a bunch of api comments in lz4.h
2018-09-13 16:02:11 -07:00
Yann Collet
86023f01f2 avoid final trailing comma for enum lists
as detected in #485 by @JoachimSchneider.

Refactored the c_standards tests
so that these issues get automatically detected in CI tests.
2018-09-13 14:29:41 -07:00
Yann Collet
4a84836c13 removed image from repository
used for v1.8.2 announcement
2018-09-12 10:50:37 -07:00