diff options
-rwxr-xr-x | hm/soispha/pkgs/scripts/wrappers/ytc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/hm/soispha/pkgs/scripts/wrappers/ytc b/hm/soispha/pkgs/scripts/wrappers/ytc index 44aeb358..ce7f9ba9 100755 --- a/hm/soispha/pkgs/scripts/wrappers/ytc +++ b/hm/soispha/pkgs/scripts/wrappers/ytc @@ -73,10 +73,10 @@ while read -r base; do printf "" > "$filename_file" if [ "$old_filename" ]; then - while [ "$(wc -l < "$files_to_play")" -gt "$CONCURRENT" ]; do + if [ "$(wc -l < "$files_to_play")" -gt "$CONCURRENT" ]; then msg2 "Waiting for '$pid' to finish as we already have '$(wc -l < "$files_to_play")' files cached" wait "$pid" - done + fi fi old_filename="$filename"; |