]> git.tuebingen.mpg.de Git - paraslash.git/commit
Teach the mood parser to not leak on errors.
authorAndre Noll <maan@tuebingen.mpg.de>
Wed, 19 Mar 2025 23:18:30 +0000 (00:18 +0100)
committerAndre Noll <maan@tuebingen.mpg.de>
Mon, 24 Mar 2025 21:42:49 +0000 (22:42 +0100)
commit726924917d84060e932b379dba6519e78cd8e79e
tree94386786d023d74f56a88dc447887f45948d2529
parent62ddb47aed8039f02e887db9dedcbbe15ab23813
Teach the mood parser to not leak on errors.

Attempting to load an incomplete mood definition such as "1 &&"
currently causes memory leaks because the memory for the partial
syntax tree is never freed.

Employ bison's %destructor directive to call mp_free_ast() whenever
a syntax error happens.
yy/mp.y