8000 bpo-40880: Fix invalid read in newline_in_string in pegen.c by pablogsal · Pull Request #20666 · python/cpython · GitHub
[go: up one dir, main page]

Skip to content

bpo-40880: Fix invalid read in newline_in_string in pegen.c #20666

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

Merged
merged 3 commits into from
Jun 5, 2020
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
bpo-40880: Fix invalid read in newline_in_string in pegen.c
  • Loading branch information
pablogsal committed Jun 5, 2020
commit c90c4bffe77564cfec97edd817eee6c8b1379fc1
2 changes: 1 addition & 1 deletion Parser/pegen/pegen.c
Original file line number Diff line number Diff line change
Expand Up @@ -937,7 +937,7 @@ _PyPegen_number_token(Parser *p)
static int // bool
newline_in_string(Parser *p, const char *cur)
{
for (char c = *cur; cur >= p->tok->buf; c = *--cur) {
for (char c = *cur; cur > p->tok->buf; c = *--cur) {
if (c == '\'' || c == '"') {
return 1;
}
Expand Down
0