summaryrefslogtreecommitdiffstats
path: root/third_party/jpeg-xl/lib/jxl/icc_codec.cc
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 01:13:27 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 01:13:27 +0000
commit40a355a42d4a9444dc753c04c6608dade2f06a23 (patch)
tree871fc667d2de662f171103ce5ec067014ef85e61 /third_party/jpeg-xl/lib/jxl/icc_codec.cc
parentAdding upstream version 124.0.1. (diff)
downloadfirefox-adbda400be353e676059e335c3c0aaf99e719475.tar.xz
firefox-adbda400be353e676059e335c3c0aaf99e719475.zip
Adding upstream version 125.0.1.upstream/125.0.1
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'third_party/jpeg-xl/lib/jxl/icc_codec.cc')
-rw-r--r--third_party/jpeg-xl/lib/jxl/icc_codec.cc6
1 files changed, 4 insertions, 2 deletions
diff --git a/third_party/jpeg-xl/lib/jxl/icc_codec.cc b/third_party/jpeg-xl/lib/jxl/icc_codec.cc
index a1f118ebfb..8501c684ac 100644
--- a/third_party/jpeg-xl/lib/jxl/icc_codec.cc
+++ b/third_party/jpeg-xl/lib/jxl/icc_codec.cc
@@ -33,7 +33,8 @@ void Shuffle(uint8_t* data, size_t size, size_t width) {
size_t height = (size + width - 1) / width; // amount of rows of output
PaddedBytes result(size);
// i = output index, j input index
- size_t s = 0, j = 0;
+ size_t s = 0;
+ size_t j = 0;
for (size_t i = 0; i < size; i++) {
result[i] = data[j];
j += height;
@@ -55,7 +56,8 @@ uint64_t DecodeVarInt(const uint8_t* input, size_t inputSize, size_t* pos) {
size_t i;
uint64_t ret = 0;
for (i = 0; *pos + i < inputSize && i < 10; ++i) {
- ret |= uint64_t(input[*pos + i] & 127) << uint64_t(7 * i);
+ ret |= static_cast<uint64_t>(input[*pos + i] & 127)
+ << static_cast<uint64_t>(7 * i);
// If the next-byte flag is not set, stop
if ((input[*pos + i] & 128) == 0) break;
}