diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-15 03:35:49 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-15 03:35:49 +0000 |
commit | d8bbc7858622b6d9c278469aab701ca0b609cddf (patch) | |
tree | eff41dc61d9f714852212739e6b3738b82a2af87 /third_party/jpeg-xl/lib/jpegli/decode_api_test.cc | |
parent | Releasing progress-linux version 125.0.3-1~progress7.99u1. (diff) | |
download | firefox-d8bbc7858622b6d9c278469aab701ca0b609cddf.tar.xz firefox-d8bbc7858622b6d9c278469aab701ca0b609cddf.zip |
Merging upstream version 126.0.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to '')
-rw-r--r-- | third_party/jpeg-xl/lib/jpegli/decode_api_test.cc | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/third_party/jpeg-xl/lib/jpegli/decode_api_test.cc b/third_party/jpeg-xl/lib/jpegli/decode_api_test.cc index 0cc5a194d7..3ecd479951 100644 --- a/third_party/jpeg-xl/lib/jpegli/decode_api_test.cc +++ b/third_party/jpeg-xl/lib/jpegli/decode_api_test.cc @@ -3,8 +3,8 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. -#include <cmath> #include <cstdint> +#include <cstdio> #include <vector> #include "lib/jpegli/decode.h" @@ -78,7 +78,8 @@ class SourceManager { return TRUE; } - static void skip_input_data(j_decompress_ptr cinfo, long num_bytes) { + static void skip_input_data(j_decompress_ptr cinfo, + long num_bytes /* NOLINT */) { auto* src = reinterpret_cast<SourceManager*>(cinfo->src); if (num_bytes <= 0) { return; @@ -447,7 +448,7 @@ std::vector<TestConfig> GenerateBasicConfigs() { TEST(DecodeAPITest, ReuseCinfoSameMemSource) { std::vector<TestConfig> all_configs = GenerateBasicConfigs(); uint8_t* buffer = nullptr; - unsigned long buffer_size = 0; + unsigned long buffer_size = 0; // NOLINT { jpeg_compress_struct cinfo; const auto try_catch_block = [&]() -> bool { @@ -502,7 +503,7 @@ TEST(DecodeAPITest, ReuseCinfoSameStdSource) { EXPECT_TRUE(try_catch_block()); jpegli_destroy_compress(&cinfo); } - rewind(tmpf); + fseek(tmpf, 0, SEEK_SET); std::vector<TestImage> all_outputs(all_configs.size()); { jpeg_decompress_struct cinfo; @@ -527,9 +528,9 @@ TEST(DecodeAPITest, ReuseCinfoSameStdSource) { TEST(DecodeAPITest, AbbreviatedStreams) { uint8_t* table_stream = nullptr; - unsigned long table_stream_size = 0; + unsigned long table_stream_size = 0; // NOLINT uint8_t* data_stream = nullptr; - unsigned long data_stream_size = 0; + unsigned long data_stream_size = 0; // NOLINT { jpeg_compress_struct cinfo; const auto try_catch_block = [&]() -> bool { |