shithub: riscv

Download patch

ref: 538b8107122d55be6a941384dc499d56b35f99e1
parent: 85bfb0e9ebb8f2238cff6c03e93c0dce31581845
author: cinap_lenrek <[email protected]>
date: Mon Jan 10 12:41:46 EST 2022

rc: fix pwrd() regression, forgot <= ' ' case from needsrcquote()... sorry :(

--- a/sys/src/cmd/rc/io.c
+++ b/sys/src/cmd/rc/io.c
@@ -138,7 +138,7 @@
 pwrd(io *f, char *s)
 {
 	char *t;
-	for(t = s;*t;t++) if(*t >= 0 && strchr("`^#*[]=|\\?${}()'<>&;", *t)) break;
+	for(t = s;*t;t++) if(*t >= 0 && (*t <= ' ' || strchr("`^#*[]=|\\?${}()'<>&;", *t))) break;
 	if(t==s || *t)
 		pquo(f, s);
 	else pstr(f, s);