mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-26 09:30:24 +00:00
LibWasm: Read indices as LEB128 u32s
Every type of index was previously being read as a size_t.
This commit is contained in:
parent
78c56d80f9
commit
20d8ea4db1
Notes:
sideshowbarker
2024-07-16 22:17:03 +09:00
Author: https://github.com/dzfrias Commit: https://github.com/LadybirdBrowser/ladybird/commit/20d8ea4db1 Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/185 Reviewed-by: https://github.com/alimpfard
1 changed files with 1 additions and 1 deletions
|
@ -82,7 +82,7 @@ template<typename T>
|
|||
struct GenericIndexParser {
|
||||
static ParseResult<T> parse(Stream& stream)
|
||||
{
|
||||
auto value_or_error = stream.read_value<LEB128<size_t>>();
|
||||
auto value_or_error = stream.read_value<LEB128<u32>>();
|
||||
if (value_or_error.is_error())
|
||||
return with_eof_check(stream, ParseError::ExpectedIndex);
|
||||
size_t value = value_or_error.release_value();
|
||||
|
|
Loading…
Reference in a new issue