mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 05:37:34 +00:00
LibCompress: Add two missing return statements
This commit is contained in:
parent
9d5049230c
commit
c96e663b0a
1 changed files with 2 additions and 2 deletions
|
@ -415,7 +415,7 @@ ErrorOr<void> DeflateDecompressor::decode_codes(CanonicalCode& literal_code, Opt
|
||||||
|
|
||||||
auto literal_code_result = CanonicalCode::from_bytes(code_lengths.span().trim(literal_code_count));
|
auto literal_code_result = CanonicalCode::from_bytes(code_lengths.span().trim(literal_code_count));
|
||||||
if (!literal_code_result.has_value())
|
if (!literal_code_result.has_value())
|
||||||
Error::from_string_literal("Failed to decode the literal code");
|
return Error::from_string_literal("Failed to decode the literal code");
|
||||||
literal_code = literal_code_result.value();
|
literal_code = literal_code_result.value();
|
||||||
|
|
||||||
// Now we extract the code that was used to encode distances in the block.
|
// Now we extract the code that was used to encode distances in the block.
|
||||||
|
@ -431,7 +431,7 @@ ErrorOr<void> DeflateDecompressor::decode_codes(CanonicalCode& literal_code, Opt
|
||||||
|
|
||||||
auto distance_code_result = CanonicalCode::from_bytes(code_lengths.span().slice(literal_code_count));
|
auto distance_code_result = CanonicalCode::from_bytes(code_lengths.span().slice(literal_code_count));
|
||||||
if (!distance_code_result.has_value())
|
if (!distance_code_result.has_value())
|
||||||
Error::from_string_literal("Failed to decode the distance code");
|
return Error::from_string_literal("Failed to decode the distance code");
|
||||||
distance_code = distance_code_result.value();
|
distance_code = distance_code_result.value();
|
||||||
|
|
||||||
return {};
|
return {};
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue