# HG changeset patch # User lost # Date 1251707413 0 # Node ID 3010e24bb9c59b49cf2a4b108746d465ed5482b6 # Parent 88bbffa404ea0908c3750c428e53400d57d5b12d Fix crashing on bad expressions on pass 2 diff -r 88bbffa404ea -r 3010e24bb9c5 lwasm/parse.c --- a/lwasm/parse.c Sun Aug 16 17:18:11 2009 +0000 +++ b/lwasm/parse.c Mon Aug 31 08:30:13 2009 +0000 @@ -187,7 +187,7 @@ (instab[opnum].fn)(as, l, &p2, opnum); // if we didn't end on a "space" character or EOL, throw error - if (*p2 && !isspace(*p2) && !(l -> err) && as -> passnum == 1) + if (as -> passnum == 1 && *p2 && !isspace(*p2) && !(l -> err)) register_error(as, l, 1, "Bad operand: %s (%d)", p2, as -> passnum); } else