From 154cd6e32971e63ecfcffd8a62d4fecd88e75651 Mon Sep 17 00:00:00 2001 From: Max Triano Date: Tue, 23 Jun 2020 15:28:15 -0400 Subject: [PATCH] Clarifying comments --- src/exec/command.rs | 3 ++- src/walk.rs | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/src/exec/command.rs b/src/exec/command.rs index 1baa15d..5d546f2 100644 --- a/src/exec/command.rs +++ b/src/exec/command.rs @@ -13,7 +13,8 @@ pub fn execute_command(mut cmd: Command, out_perm: &Mutex<()>, is_multithread: b if is_multithread { output = cmd.output(); } else { - // This sort of works: + // If running on only one thread, don't buffer output + // Allows for viewing and interacting with intermediate command output let child = cmd.spawn().expect("Failed to execute command"); output = child.wait_with_output(); } diff --git a/src/walk.rs b/src/walk.rs index 9da49aa..866205e 100644 --- a/src/walk.rs +++ b/src/walk.rs @@ -170,6 +170,7 @@ fn spawn_receiver( let show_filesystem_errors = config.show_filesystem_errors; let threads = config.threads; + // This will be used to check if output should be buffered when only running a single thread let is_multithread: bool = if threads > 1 { true } else {