[*] fix optionals
This commit is contained in:
parent
4f340aae47
commit
db37b81729
@ -89,7 +89,7 @@ namespace Aurora::Compression
|
||||
if (meta.uOptWindowBits.value() <= BROTLI_MAX_INPUT_BLOCK_BITS &&
|
||||
meta.uOptWindowBits.value() >= BROTLI_MIN_INPUT_BLOCK_BITS)
|
||||
{
|
||||
if (!BrotliEncoderSetParameter(this->pState, BrotliEncoderParameter::BROTLI_PARAM_LGWIN, meta.uOptWindowBits))
|
||||
if (!BrotliEncoderSetParameter(this->pState, BrotliEncoderParameter::BROTLI_PARAM_LGWIN, meta.uOptWindowBits.value()))
|
||||
{
|
||||
SysPushErrorArg("Compressor couldn't set window bits");
|
||||
return false;
|
||||
|
@ -398,7 +398,10 @@ namespace Aurora::Parse
|
||||
}
|
||||
case ParsableTag::kParseUUID:
|
||||
{
|
||||
uuid = uuids::uuid::from_string(str);
|
||||
if (auto uuid2 = uuids::uuid::from_string(str))
|
||||
{
|
||||
uuid = *uuid2;
|
||||
}
|
||||
if (!uuid.has_value())
|
||||
{
|
||||
SysPushErrorSyntaxError("Parse Error: invalid UUID {}", str);
|
||||
|
Loading…
Reference in New Issue
Block a user