shithub: riscv

Download patch

ref: 6d96b35fadcb7d2f4fee5cc03f2155a6aaa472da
parent: 9e926eeb4e3c716bcbd11377c131061cd06900ef
author: aiju <devnull@localhost>
date: Mon Sep 5 11:48:46 EDT 2016

pc(1): bugfix: allow setting output base to 0 (thanks, deuteron)

--- a/sys/src/cmd/pc.y
+++ b/sys/src/cmd/pc.y
@@ -388,7 +388,7 @@
 		save = outbase;
 		if(!fail) 
 			outbase = mptoi($3);
-		if(outbase != 2 && outbase != 8 && outbase != 10 && outbase != 16){
+		if(outbase != 0 && outbase != 2 && outbase != 8 && outbase != 10 && outbase != 16){
 			error("no.");
 			outbase = save;
 		}