From 4ac1148428b62a60854e405c67f4d003ca1368e1 Mon Sep 17 00:00:00 2001 From: Francisco Demartino Date: Tue, 15 Dec 2020 14:03:48 -0300 Subject: [PATCH] quote paths on exiftool calls --- diff-image | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/diff-image b/diff-image index 4b3640f..1da14a4 100755 --- a/diff-image +++ b/diff-image @@ -201,10 +201,10 @@ do_compare() if which xdg-open > /dev/null then # Get width and height of each input image. - f1_width="$(exiftool -S -ImageWidth $f1 | cut -d' ' -f2)" - f2_width="$(exiftool -S -ImageWidth $f2 | cut -d' ' -f2)" - f1_height="$(exiftool -S -ImageHeight $f1 | cut -d' ' -f2)" - f2_height="$(exiftool -S -ImageHeight $f2 | cut -d' ' -f2)" + f1_width="$(exiftool -S -ImageWidth "$f1" | cut -d' ' -f2)" + f2_width="$(exiftool -S -ImageWidth "$f2" | cut -d' ' -f2)" + f1_height="$(exiftool -S -ImageHeight "$f1" | cut -d' ' -f2)" + f2_height="$(exiftool -S -ImageHeight "$f2" | cut -d' ' -f2)" # find the max of each. if (( $(echo "$f1_width > $f2_width" |bc -l) )); then max_file_width=$f1_width