replace all whitespace by a single space - tscrape - twitter scraper | |
git clone git://git.codemadness.org/tscrape | |
Log | |
Files | |
Refs | |
README | |
LICENSE | |
--- | |
commit 7ed31cfe093fa52711f0bdd407abc1e4d67f11b3 | |
parent d4929d30226753c84a2ab5d8b703dd7df69eb4c1 | |
Author: Hiltjo Posthuma <[email protected]> | |
Date: Fri, 5 Jun 2020 17:18:40 +0200 | |
replace all whitespace by a single space | |
Diffstat: | |
M tscrape.c | 2 +- | |
1 file changed, 1 insertion(+), 1 deletion(-) | |
--- | |
diff --git a/tscrape.c b/tscrape.c | |
@@ -174,7 +174,7 @@ printexpand(const char *s) | |
struct url *u; | |
for (; *s; s++) { | |
- if (*s == '\n') { | |
+ if (isspace((unsigned char)*s)) { | |
putchar(' '); | |
continue; | |
} else if (iscntrl((unsigned char)*s)) { |