diff options
Diffstat (limited to 'src/WebAssembly/BinaryFormat/Decoder.php')
| -rw-r--r-- | src/WebAssembly/BinaryFormat/Decoder.php | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/WebAssembly/BinaryFormat/Decoder.php b/src/WebAssembly/BinaryFormat/Decoder.php index 2e59df4..e64fac8 100644 --- a/src/WebAssembly/BinaryFormat/Decoder.php +++ b/src/WebAssembly/BinaryFormat/Decoder.php @@ -78,6 +78,8 @@ final class Decoder $codes = $this->decodeSection(SectionId::Code, $this->decodeCodeSecRest(...)) ?? []; $datas = $this->decodeSection(SectionId::Data, $this->decodeDataSecRest(...)) ?? []; + $this->skipCustomSections(); + if (!$this->stream->eof()) { throw new InvalidBinaryFormatException("eof"); } |
