_Bug_
Got the following error after cloning and running make:
paste.c: In function ‘parallel’:
paste.c:70:4: warning: this ‘else’ clause does not guard... [-Wmisleading-indentation]
else
^~~~
paste.c:72:5: note: ...this statement, but the latter is misleadingly indented as if it is guarded by the ‘else’
last++;
^~~~
This patch preserves the same functionality and just adjusts indentation to squelch the warning.
_Test plan_
Used the following 'script' to convince myself output looked correct for inputs
where the latter arguments to paste had fewer lines.
make && printf "1\n2\n" > two.txt && printf "" > zero.txt && ./paste -d, two.txt zero.txt
---
paste.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/paste.c b/paste.c
index 77fc090..1d4e9f6 100644
--- a/paste.c
+++ b/paste.c
_AT_@ -69,7 +69,7 @@ nextline:
putchar('\n');
else
efputrune(&d, stdout, "<stdout>");
- last++;
+ last++;
}
}
if (last != -1)
--
2.9.3
Received on Tue Dec 27 2016 - 01:22:36 CET