mirror of https://github.com/acidanthera/audk.git
MdeModulePkg/BrotliCustomDecompressLib: Correct BrotliDecompress
We need to pass DestSize as pointer, because we assign this output var to TotalOut value inside BrotliDecompress routine Signed-off-by: Savva Mitrofanov <savvamtr@gmail.com>
This commit is contained in:
parent
b97a76470a
commit
1a35fd886d
|
@ -82,7 +82,7 @@ BrotliDecompress (
|
||||||
IN CONST VOID *Source,
|
IN CONST VOID *Source,
|
||||||
IN UINTN SourceSize,
|
IN UINTN SourceSize,
|
||||||
IN OUT VOID *Destination,
|
IN OUT VOID *Destination,
|
||||||
IN OUT UINTN DestSize,
|
IN OUT UINTN *DestSize,
|
||||||
IN VOID *BuffInfo
|
IN VOID *BuffInfo
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
|
@ -157,7 +157,7 @@ BrotliDecompress (
|
||||||
CopyMem (Temp, Output, (size_t)(NextOut - Output));
|
CopyMem (Temp, Output, (size_t)(NextOut - Output));
|
||||||
}
|
}
|
||||||
|
|
||||||
DestSize = TotalOut;
|
*DestSize = TotalOut;
|
||||||
|
|
||||||
BrFree (BuffInfo, Input);
|
BrFree (BuffInfo, Input);
|
||||||
BrFree (BuffInfo, Output);
|
BrFree (BuffInfo, Output);
|
||||||
|
@ -292,7 +292,7 @@ BrotliUefiDecompress (
|
||||||
(VOID *)((UINT8 *)Source + BROTLI_SCRATCH_MAX),
|
(VOID *)((UINT8 *)Source + BROTLI_SCRATCH_MAX),
|
||||||
SourceSize - BROTLI_SCRATCH_MAX,
|
SourceSize - BROTLI_SCRATCH_MAX,
|
||||||
Destination,
|
Destination,
|
||||||
DestSize,
|
&DestSize,
|
||||||
(VOID *)(&BroBuff)
|
(VOID *)(&BroBuff)
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue