]> git.proxmox.com Git - pve-storage.git/blobdiff - PVE/Diskmanage.pm
diskmanage: fix determining array length
[pve-storage.git] / PVE / Diskmanage.pm
index 55da2e5f285a34b70c5c9e27fa8220866efb8710..ca6f0b7bc5dc9cd5172bd3ba8de0bd967f852f8d 100644 (file)
@@ -915,7 +915,7 @@ sub wipe_blockdev {
        push $to_wipe->@*, "/dev/${part}" if -b "/dev/${part}";
     });
 
-    if (scalar($to_wipe->$#*) > 0) {
+    if (scalar($to_wipe->@*) > 0) {
        print "found child partitions to wipe: ". join(', ', $to_wipe->@*) ."\n";
     }
     push $to_wipe->@*, $devpath; # put actual device last