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 heap buffer overflow in function yaml_emitter_emit_flow_sequence_… #259

Closed
wants to merge 1 commit into from

Conversation

ziyangc97
Copy link

…item, releated issue:#258

@ziyangc97
Copy link
Author

In this PR, I not sure what to do when STACK_EMPTY check is failed. Are we going to print error log and return to end the process, or do we set indent to 0 and continue the process ?

@perlpunk
Copy link
Member

perlpunk commented Apr 3, 2024

Do you know how the problem can be reproduced?

@perlpunk
Copy link
Member

perlpunk commented Apr 4, 2024

As mentioned in #258, I think this shouldn't even happen, and something is wrong already before. The state machine should not get into this position. So I think this wouldn't fix it.

@perlpunk
Copy link
Member

perlpunk commented Apr 8, 2024

I think #290 is a more general fix for this

@perlpunk
Copy link
Member

Closing this as it would only be a partial fix (same problem in yaml_emitter_emit_flow_mapping_key), and actually this code shouldn't be called anyway as it only happens when calling yaml_emitter_close after a failing yaml_emitter_dump, see comments in #258 (comment)

@perlpunk perlpunk closed this Apr 18, 2024
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