projects
/
pspp
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f49d854
)
macro: Fix memory leak expanding !DO loop over list.
author
Ben Pfaff
<blp@cs.stanford.edu>
Sat, 9 Oct 2021 16:32:02 +0000
(09:32 -0700)
committer
Ben Pfaff
<blp@cs.stanford.edu>
Sat, 9 Oct 2021 16:32:02 +0000
(09:32 -0700)
Found by Address Sanitizer.
src/language/lexer/macro.c
patch
|
blob
|
history
diff --git
a/src/language/lexer/macro.c
b/src/language/lexer/macro.c
index 62d060aad2ce21bc6320c0f05960f46051993cd4..bced649ec3b08481e352db101bd7b8410b6b3e26 100644
(file)
--- a/
src/language/lexer/macro.c
+++ b/
src/language/lexer/macro.c
@@
-1836,6
+1836,7
@@
macro_expand_do (const struct macro_token *tokens, size_t n_tokens,
macro_expand (p, do_end - p, &subme, exp);
}
+ macro_tokens_uninit (&items);
return do_end - tokens + 1;
}
else if (p < end && p->token.type == T_EQUALS)