summaryrefslogtreecommitdiff
path: root/src/files.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/files.rs')
-rw-r--r--src/files.rs3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/files.rs b/src/files.rs
index 9a33e5e..849de77 100644
--- a/src/files.rs
+++ b/src/files.rs
@@ -146,8 +146,9 @@ pub fn reencode_files(conn: Connection, handler: Arc<AtomicBool>, threads: usize
let lock = Arc::new(Mutex::new(conn));
while handler.load(Ordering::SeqCst) {
- while *thread_counter.read().unwrap() >= threads {
+ if *thread_counter.read().unwrap() >= threads {
sleep(time::Duration::from_millis(100));
+ continue;
}
let file = match files.next() {