From 1ac69798857ccf6e510c40c2537157c0144907ea Mon Sep 17 00:00:00 2001 From: utf8please Date: Sun, 27 Mar 2022 20:04:49 -0700 Subject: [PATCH] Limit result to one line when parsing cover size. --- AAXtoMP3 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/AAXtoMP3 b/AAXtoMP3 index 670f2e5..25999be 100755 --- a/AAXtoMP3 +++ b/AAXtoMP3 @@ -807,7 +807,7 @@ do fi extra_crop_cover='' - cover_width=$(ffprobe -i "${cover_file}" 2>&1 | $GREP -Po "[0-9]+(?=x[0-9]+)") + cover_width=$(ffprobe -i "${cover_file}" 2>&1 | $GREP -Po "[0-9]+(?=x[0-9]+)" | tail -n 1) if (( ${cover_width} % 2 == 1 )); then if [ "$((${loglevel} > 1))" == "1" ]; then log "Cover ${cover_file} has odd width ${cover_width}, setting extra_crop_cover to make even."