[hackers] [sbase] replace printf + putchar with fputs || Evan Gates
commit e34007d8950cadf8fc9162d350e42d4b34fc4412
Author: Evan Gates <evan.gates_AT_gmail.com>
Date: Fri Feb 20 12:14:51 2015 -0800
replace printf + putchar with fputs
diff --git a/Makefile b/Makefile
index 337b33e..1339299 100644
--- a/Makefile
+++ b/Makefile
_AT_@ -210,8 +210,8 @@ sbase-box: $(LIB) $(SRC)
echo "else if (!strcmp(s, \"[\")) return test_main(argc, argv);" >> build/$_AT_.c
for f in $(SRC); do echo "else if(!strcmp(s, \"$${f%.c}\")) return $${f%.c}_main(argc, argv);" >> build/$_AT_.c; done
echo 'else {' >> build/$_AT_.c
- echo "printf(\"[\"); putchar(' ');" >> build/$_AT_.c
- for f in $(SRC); do echo "printf(\"$${f%.c}\"); putchar(' ');" >> build/$_AT_.c; done
+ echo "fputs(\"[ \", stdout);" >> build/$_AT_.c
+ for f in $(SRC); do echo "fputs(\"$${f%.c} \", stdout);" >> build/$_AT_.c; done
echo "putchar(0xa); }; return 0; }" >> build/$_AT_.c
$(LD) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) -o $_AT_ build/*.c $(LIB)
rm -r build
Received on Sat Feb 21 2015 - 10:33:31 CET
This archive was generated by hypermail 2.3.0
: Sat Feb 21 2015 - 10:36:34 CET