[git commit] reset: before calling execvp(), reset needs to flush stdout
Denys Vlasenko
vda.linux at googlemail.com
Fri Feb 17 22:02:06 UTC 2017
commit: https://git.busybox.net/busybox/commit/?id=02a2a278f6684f742fe131e1b598ca01cfa240db
branch: https://git.busybox.net/busybox/commit/?id=refs/heads/master
Signed-off-by: Glenn Matthews <glmatthe at cisco.com>
Signed-off-by: Denys Vlasenko <vda.linux at googlemail.com>
---
console-tools/reset.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/console-tools/reset.c b/console-tools/reset.c
index 57cebb4..587c0d1 100644
--- a/console-tools/reset.c
+++ b/console-tools/reset.c
@@ -56,6 +56,8 @@ int reset_main(int argc UNUSED_PARAM, char **argv UNUSED_PARAM)
#if ENABLE_STTY
return stty_main(2, (char**)args);
#else
+ /* Make sure stdout gets drained before we execvp */
+ fflush_all();
execvp("stty", (char**)args);
#endif
}
More information about the busybox-cvs
mailing list