[hackers] [scc] Fix regression of commit e6e455c || Roberto E. Vargas Caballero
commit adeca5a4f37c9dde9cd0fcd5f5bbc026c23db82f
Author: Roberto E. Vargas Caballero <k0ga_AT_shike2.com>
AuthorDate: Fri Aug 14 07:32:47 2015 +0200
Commit: Roberto E. Vargas Caballero <k0ga_AT_shike2.com>
CommitDate: Fri Aug 14 16:21:16 2015 +0200
Fix regression of commit e6e455c
The test for the string was not to avoid crashes, was to avoid
print something in the case of OCOLON, which is only a way to get
three children in a binary tree.
diff --git a/cc1/code.c b/cc1/code.c
index bb2f9d0..ca4be29 100644
--- a/cc1/code.c
+++ b/cc1/code.c
_AT_@ -307,7 +307,8 @@ emitbin(unsigned op, void *arg)
emitnode(np->left);
emitnode(np->right);
- printf("\t%s", optxt[op]);
+ if ((s = optxt[op]) != NULL) /* do not print in OCOLON case */
+ printf("\t%s", optxt[op]);
emitletter(np->type);
}
Received on Fri Aug 14 2015 - 17:08:59 CEST
This archive was generated by hypermail 2.3.0
: Fri Aug 14 2015 - 17:12:24 CEST