1
0
mirror of https://github.com/facebook/zstd.git synced 2025-07-03 14:29:56 +02:00
Commit Graph

37 Commits

Author SHA1 Message Date
5b266196a4 Add support for in-place decompression
* Add a function and macro ZSTD_decompressionMargin() that computes the
  decompression margin for in-place decompression. The function computes
  a tight margin that works in all cases, and the macro computes an upper
  bound that will only work if flush isn't used.
* When doing in-place decompression, make sure that our output buffer
  doesn't overlap with the input buffer. This ensures that we don't
  decide to use the portion of the output buffer that overlaps the input
  buffer for temporary memory, like for literals.
* Add a simple unit test.
* Add in-place decompression to the simple_round_trip and
  stream_round_trip fuzzers. This should help verify that our margin stays
  correct.
2023-01-12 16:28:08 -08:00
5d693cc38c Coalesce Almost All Copyright Notices to Standard Phrasing
```
for f in $(find . \( -path ./.git -o -path ./tests/fuzz/corpora -o -path ./tests/regression/data-cache -o -path ./tests/regression/cache \) -prune -o -type f); do sed -i '/Copyright .* \(Yann Collet\)\|\(Meta Platforms\)/ s/Copyright .*/Copyright (c) Meta Platforms, Inc. and affiliates./' $f; done

git checkout HEAD -- build/VS2010/libzstd-dll/libzstd-dll.rc build/VS2010/zstd/zstd.rc tests/test-license.py contrib/linux-kernel/test/include/linux/xxhash.h examples/streaming_compression_thread_pool.c lib/legacy/zstd_v0*.c lib/legacy/zstd_v0*.h
nano ./programs/windres/zstd.rc
nano ./build/VS2010/zstd/zstd.rc
nano ./build/VS2010/libzstd-dll/libzstd-dll.rc
```
2022-12-20 12:52:34 -05:00
8927f985ff Update Copyright Headers 'Facebook' -> 'Meta Platforms'
```
for f in $(find . \( -path ./.git -o -path ./tests/fuzz/corpora \) -prune -o -type f);
do
  sed -i 's/Facebook, Inc\./Meta Platforms, Inc. and affiliates./' $f;
done
```
2022-12-20 12:37:57 -05:00
a494308ae9 [copyright][license] Switch to yearless copyright and some cleanup in the linux-kernel files
* Switch to yearless copyright per FB policy
* Fix up SPDX-License-Identifier lines in `contrib/linux-kernel` sources
* Add zstd copyright/license header to the `contrib/linux-kernel` sources
* Update the `tests/test-license.py` to check for yearless copyright
* Improvements to `tests/test-license.py`
* Check `contrib/linux-kernel` in `tests/test-license.py`
2021-03-30 10:30:43 -07:00
66e811d782 [license] Update year to 2021 2021-01-04 17:53:52 -05:00
6028827fee Rewrite Include Paths to be Relative
Addresses #1998.
2020-05-04 15:20:26 -04:00
ac58c8d720 Fix copyright and license lines
* All copyright lines now have -2020 instead of -present
* All copyright lines include "Facebook, Inc"
* All licenses are now standardized

The copyright in `threading.{h,c}` is not changed because it comes from
zstdmt.

The copyright and license of `divsufsort.{h,c}` is not changed.
2020-03-26 17:02:06 -07:00
5922f4e2ae [legacy] Return the right error code 2019-04-17 11:34:52 -07:00
450feb0f95 [libzstd] Fix ZSTD_decompressBound() on bad skippable frames
The function didn't verify that the skippable frame size is correct.
2019-04-17 11:29:42 -07:00
186ded6d91 Fix typo in legacy documentation 2019-03-19 01:44:08 -07:00
20aa1b455c Stylistic changes 2019-03-17 19:35:43 -07:00
19b75b6ecb Test new ZSTD_findFrameCompressedSize and update documentation 2019-03-15 18:04:19 -07:00
8cd423a659 Reorder declaration in ZSTD_findFrameSizeInfoLegacy 2019-03-15 16:20:34 -07:00
60796e76b0 Add legacy support to decompressBound 2019-03-15 16:10:37 -07:00
e0cb8d19c6 fixed legacy test case 2018-03-20 17:48:22 -07:00
3128e03be6 updated license header
to clarify dual-license meaning as "or"
2017-09-08 00:09:23 -07:00
7db552676e reduced pool queue to 0 to save memory
fixed : pool performance when jobs are fires fast and queueSize==0
2017-08-19 15:07:54 -07:00
32fb407c9d updated a bunch of headers
for the new license
2017-08-18 16:52:05 -07:00
9830aeeea6 Fix legacy support=0 case and accidental double include of version headers 2017-03-13 17:19:37 -07:00
334cb34edb ZSTD_LEGACY_SUPPORT defines lowest supported version 2017-03-13 14:32:30 -07:00
9050e1925e Change name to to findFrameCompressedSize and add skippable support 2017-02-22 12:12:34 -08:00
d7bfcac18a Expose frameSrcSize to experimental API 2017-02-10 11:55:44 -08:00
4e709712e1 Decompressed size functions now handle multiframes and distinguish cases
- Add ZSTD_findDecompressedSize
    - Traverses multiple frames to find total output size
- Add ZSTD_getFrameContentSize
    - Gets the decompressed size of a single frame by reading header
- Deprecate ZSTD_getDecompressedSize
2017-02-08 14:50:10 -08:00
4ded9e591c added boilerplate 2016-08-30 11:06:28 -07:00
767d8f66fa legacy contexts can be re-used 2016-08-28 08:19:47 -07:00
4bf317dd00 first version supporting legacy streams (transparent decoding) 2016-08-28 07:43:34 -07:00
fca90f8f60 legacy decoder for v0.7 format 2016-07-25 17:49:08 +02:00
19c27d27f1 simplified legacy functions, no longer need magic number 2016-07-07 14:40:13 +02:00
f323bf7d32 added : ZSTD_getDecompressedSize() 2016-07-07 13:14:21 +02:00
289bbd52e5 Updated huff0 2016-06-11 01:31:54 +02:00
bf853d5510 added legacy decoder for v0.6 format 2016-06-09 17:59:18 +02:00
18dedece91 Support legacy ZSTD_decompress_usingDict() (starting v0.5+) 2016-05-06 16:43:23 +02:00
029267ab3f Integrated Legacy v0.5.x decoder (provided by @inikep) 2016-04-09 09:42:27 +02:00
464fa996e9 added v0.4 legacy support 2016-02-03 01:09:46 +01:00
ffec740d37 fixed visual and clang errors 2016-01-21 15:50:11 +01:00
29a2c838c5 support for legacy 0.3 format 2015-11-26 16:02:04 +01:00
aa074051d6 decoding support for legacy v0.2 format 2015-10-30 11:21:50 +01:00