Skip to content
This repository has been archived by the owner on Aug 2, 2022. It is now read-only.

unit test ensuring that OOB table init allowed on set code; fails on action #7736

Merged
merged 3 commits into from
Aug 9, 2019

Conversation

spoonincode
Copy link
Contributor

Change Description

Out of bound table elements are accepted during setcode but then fail later when the wasm module is actually instantiated when an action is executed. This is arguably the correct behavior when viewed from the standpoint of the wasm spec. However, it's probably not what we intended -- OOB memory init is caught during setcode.

Regardless, this goof isn't really a problem. But, this goof is now consensus. So add a unit test for this goofy behavior.

Consensus Changes

  • Consensus Changes

API Changes

  • API Changes

Documentation Additions

  • Documentation Additions

…action

Out of bound table elements are accepted during setcode but then fail later when the wasm module is actually instantiated when an action is executed. This is arguably the correct behavior when viewed from the standpoint of the wasm spec. However, it's probably not what we intended -- OOB memory init is caught during setcode.

Regardless, this goof isn't really a problem. But, this goof is now consensus. So add a unit test for this goofy behavior.
unittests/wasm_tests.cpp Show resolved Hide resolved
@spoonincode spoonincode merged commit 2d85c2f into develop Aug 9, 2019
@spoonincode spoonincode deleted the table_oob_unittest branch August 9, 2019 01:39
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants