[pve-devel] [PATCH 1/2] fix disk parser

Wolfgang Link w.link at proxmox.com
Fri Nov 6 15:53:53 CET 2015


---
 pve-zsync | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/pve-zsync b/pve-zsync
index c7e6e81..c54441d 100644
--- a/pve-zsync
+++ b/pve-zsync
@@ -774,13 +774,13 @@ sub parse_disks {
 	    $disks->{$num}->{all} .= "\/$disk";
 
 	    $num++;
-	} elsif ($vm_type eq 'lxc' && $path =~ m/^\/(\w+.+)\/(\w+.*)(\/$disk)$/) {
+	} elsif ($vm_type eq 'lxc' && $path =~ m/^\/(\w+.+)(\/(\w+.*))*(\/$disk)$/) {
 
 	    $disks->{$num}->{pool} = $1;
 	    $disks->{$num}->{all} = $disks->{$num}->{pool};
 
 	    if ($2) {
-		$disks->{$num}->{path} = $2;
+		$disks->{$num}->{path} = $3;
 		$disks->{$num}->{all} .= "\/$disks->{$num}->{path}";
 	    }
 
-- 
2.1.4




More information about the pve-devel mailing list