Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix opcode xtuck panic #932

Merged
merged 2 commits into from Jun 3, 2019
Merged

fix opcode xtuck panic #932

merged 2 commits into from Jun 3, 2019

Conversation

laizy
Copy link
Contributor

@laizy laizy commented May 30, 2019

No description provided.

Honglei-Cong
Honglei-Cong previously approved these changes May 30, 2019
@@ -47,8 +47,8 @@ func (r *RandomAccessStack) Insert(index int, t types.StackItems) {
return
}
index = l - index
r.e = append(r.e, r.e[l-1])
copy(r.e[index+1:l], r.e[index:])
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why it need to be updated?

@@ -78,7 +78,7 @@ func opDCALL(e *ExecutionEngine) (VMState, error) {
return FAULT, errors.ERR_DCALL_OFFSET_ERROR
}

if dest.Sign() < 0 || dest.Cmp(big.NewInt(int64(len(e.Context.Code)))) > 0 {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why it need to add equal zero?

@laizy laizy merged commit cac00a2 into ontio:master Jun 3, 2019
@laizy laizy deleted the fix-neovm-bug branch June 3, 2019 11:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants