From f98a1c4a1cf61ff7d6483388ca1fac365fb0b31b Mon Sep 17 00:00:00 2001 From: Tavian Barnes Date: Thu, 10 Nov 2022 11:02:19 -0500 Subject: Revert "exec: Don't flush if the user says no to -ok" From the bfs_ctx_flush() implementation: // Before executing anything, flush all open streams. This ensures that // - the user sees everything relevant before an -ok[dir] prompt But that only works if we call it before the prompt. This reverts commit 21344dfb72f9b65b366ca5f754f1bc35f52da3c7. --- tests/gnu/ok_flush.sh | 4 ++++ 1 file changed, 4 insertions(+) create mode 100644 tests/gnu/ok_flush.sh (limited to 'tests/gnu/ok_flush.sh') diff --git a/tests/gnu/ok_flush.sh b/tests/gnu/ok_flush.sh new file mode 100644 index 0000000..87c7298 --- /dev/null +++ b/tests/gnu/ok_flush.sh @@ -0,0 +1,4 @@ +# I/O streams should be flushed before -ok prompts +yes | invoke_bfs basic -printf '%p ? ' -ok echo found \; 2>&1 | tr '\0' ' ' | sed 's/?.*?/?/' >"$OUT" +sort_output +diff_output -- cgit v1.2.3