Have CM_MAX_CLIPS understand new version 5 format

This commit is contained in:
Chris Down 2018-02-20 11:36:00 +00:00
parent ee0a6f6d31
commit 44d7baa27a

View file

@ -222,7 +222,7 @@ while true; do
if (( CM_MAX_CLIPS )) && [[ -f $cache_file ]]; then if (( CM_MAX_CLIPS )) && [[ -f $cache_file ]]; then
mapfile -t to_remove < <( mapfile -t to_remove < <(
head -n -"$CM_MAX_CLIPS" "$cache_file" | head -n -"$CM_MAX_CLIPS" "$cache_file" |
while read -r line; do cksum <<< "$line"; done while read -r line; do cksum <<< "${line#* }"; done
) )
num_to_remove="${#to_remove[@]}" num_to_remove="${#to_remove[@]}"
if (( num_to_remove )); then if (( num_to_remove )); then