From 9e7e5b4d283432a4cc577eb793a601fbc014ac0f Mon Sep 17 00:00:00 2001 From: Ralf Zerres Date: Sun, 3 Aug 2025 13:18:22 +0200 Subject: [PATCH] correct bug handling subvolume creation on target --- bin/dsnap-sync | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/bin/dsnap-sync b/bin/dsnap-sync index 806a12e..b9028a4 100755 --- a/bin/dsnap-sync +++ b/bin/dsnap-sync @@ -3275,7 +3275,8 @@ verify_snapper_structure () { "$backup_root/$snapper_snapshots" fi cmd="$ssh btrfs subvolume create $backup_root/$snapper_snapshots 2>/dev/null" - if ! $(eval "$cmd"); then + ret=$(eval "$cmd") + if [ -z "$ret" ]; then printf "${RED}Error: ${MAGENTA}Creation of snapper subvolume ${GREEN}%s${MAGENTA} failed${NO_COLOR}\n" \ "$backup_root/$snapper_snapshots" return 1