shithub: riscv

Download patch

ref: 5016ac0c63c3b4db1dcdace0c6136b0ac88abeea
parent: d0c6ade53dd763a92e31333fd789158304e8e842
author: Sigrid <[email protected]>
date: Tue Dec 15 09:37:36 EST 2020

pc: set exit status depending on errors

--- a/sys/src/cmd/pc.y
+++ b/sys/src/cmd/pc.y
@@ -1065,4 +1065,6 @@
 	if(in == nil) sysfatal("Bfdopen: %r");
 	extern void yyparse(void);
 	yyparse();
+	extern int yynerrs;
+	exits(yynerrs ? "error" : nil);
 }