From c79d1638f5caa5f9554c971168737ea2305ff33c Mon Sep 17 00:00:00 2001 From: sharkdp Date: Fri, 3 Apr 2020 11:51:50 +0200 Subject: [PATCH] Move MAX_BUFFER_LENGTH --- src/internal/mod.rs | 3 --- src/walk.rs | 5 ++++- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/internal/mod.rs b/src/internal/mod.rs index d35d354..0d9f695 100644 --- a/src/internal/mod.rs +++ b/src/internal/mod.rs @@ -17,9 +17,6 @@ pub fn osstr_to_bytes(input: &OsStr) -> Cow<[u8]> { } } -/// Maximum size of the output buffer before flushing results to the console -pub const MAX_BUFFER_LENGTH: usize = 1000; - /// Traverse args_os, looking for -exec and replacing it with --exec. /// /// # Returns diff --git a/src/walk.rs b/src/walk.rs index f5aef77..819d61e 100644 --- a/src/walk.rs +++ b/src/walk.rs @@ -1,7 +1,7 @@ use crate::exec; use crate::exit_codes::{merge_exitcodes, ExitCode}; use crate::fshelper; -use crate::internal::{osstr_to_bytes, MAX_BUFFER_LENGTH}; +use crate::internal::osstr_to_bytes; use crate::options::Options; use crate::output; @@ -37,6 +37,9 @@ pub enum WorkerResult { Error(ignore::Error), } +/// Maximum size of the output buffer before flushing results to the console +pub const MAX_BUFFER_LENGTH: usize = 1000; + /// Recursively scan the given search path for files / pathnames matching the pattern. /// /// If the `--exec` argument was supplied, this will create a thread pool for executing