We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Describe the bug Segfault when grammar entry rule doesn't exists
To Reproduce Steps to reproduce the behavior:
README
peppa parse -G json.peg -e entry2 data.json
Desktop (please complete the following information):
This seems to fix the problem (line numbers are from my code with other changes):
@@ -3194,9 +3330,9 @@ P4_GetErrorMessage(P4_Source* source) { return NULL; memset(source->errmsg, 0, sizeof(source->errmsg)); sprintf(source->errmsg, "line %zu:%zu, expect %s", source->error.lineno, source->error.offset, - source->error.rule->name); + source->error.rule ? source->error.rule->name : source->entry_name);
The text was updated successfully, but these errors were encountered:
bugfix: segfault when entry rule does not exist (#141).
32aef54
84473ac
77f02b4
Merge pull request #142 from soasme/issue-141
46c716b
Thanks for reporting the issue!
Sorry, something went wrong.
No branches or pull requests
Describe the bug
Segfault when grammar entry rule doesn't exists
To Reproduce
Steps to reproduce the behavior:
README
json example executepeppa parse -G json.peg -e entry2 data.json
Desktop (please complete the following information):
This seems to fix the problem (line numbers are from my code with other changes):
The text was updated successfully, but these errors were encountered: