ref: 3d2ccb36333113f1c1e71191926f2b5f5e3a64f6
parent: 289a91810b16fd9211964235252b071bf900627b
author: Roberto E. Vargas Caballero <[email protected]>
date: Thu May 7 04:09:35 EDT 2015
Fix problem in condition() If() calls to condition(), which can fail, so the Node pointer returned was not always a condition, so the call to negate could abort() because it. This patch enforces that return value of condition is always a comparition.
--- a/cc1/stmt.c
+++ b/cc1/stmt.c
@@ -56,9 +56,10 @@
expect('(');
setsafe(END_COND);
if (!setjmp(recover))
- np = iszero(expr());
+ np = expr();
else
np = symbol(zero);
+ np = iszero(np);
expect(')');
return np;
}