summaryrefslogtreecommitdiff
path: root/sys/src/cmd/aux/statusbar.c
diff options
context:
space:
mode:
authorcinap_lenrek <cinap_lenrek@gmx.de>2013-10-12 03:18:44 +0200
committercinap_lenrek <cinap_lenrek@gmx.de>2013-10-12 03:18:44 +0200
commit0f994b1b09c1dddd2d48c479dd025e71a674fd31 (patch)
tree084347d4ea64b7dbb212dc9221de0e12f9b654e0 /sys/src/cmd/aux/statusbar.c
parentab7fe19ae264aa569f6298b73492d4b3e733e0b0 (diff)
aux/statusbar: emit final newline in textmode when finished
bad: term% echo 1 1 | aux/statusbar -t x |###########################################################| 100% term% vs. good: term% echo 1 1 | aux/statusbar -t x |###########################################################| 100% term%
Diffstat (limited to 'sys/src/cmd/aux/statusbar.c')
-rw-r--r--sys/src/cmd/aux/statusbar.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/sys/src/cmd/aux/statusbar.c b/sys/src/cmd/aux/statusbar.c
index 1a6af95bb..be3314af1 100644
--- a/sys/src/cmd/aux/statusbar.c
+++ b/sys/src/cmd/aux/statusbar.c
@@ -152,7 +152,10 @@ bar(Biobuf *b)
d = strtoll(f[1], 0, 0);
drawbar();
}
- postnote(PNPROC, child, "kill");
+ if(textmode)
+ write(1, "\n", 1);
+ else
+ postnote(PNPROC, child, "kill");
}