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

vm: allow pushing empty strings #284

Merged
merged 1 commit into from
Sep 29, 2023
Merged

vm: allow pushing empty strings #284

merged 1 commit into from
Sep 29, 2023

Conversation

ixje
Copy link
Member

@ixje ixje commented Sep 29, 2023

@luc10921 reported that the following is allowed on the C# side

{ "type": "String", "value": ""  }

After some investigation is seems like the ScriptBuilder simply ignores the value and does not add anything to the stream. It will only push OpCode.PUSHDATA1 and a length 0 to the byte array. This PR fixes this scenario to also accept empty strings

@coveralls
Copy link

Coverage Status

coverage: 80.744% (-0.007%) from 80.751% when pulling e7c49ef on vm-empty-string into 4ac098c on master.

@ixje ixje merged commit 522c6dc into master Sep 29, 2023
11 checks passed
@ixje ixje deleted the vm-empty-string branch September 29, 2023 07:47
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.

2 participants