all lists on lists.proxmox.com
 help / color / mirror / Atom feed
* [pve-devel] [PATCH storage] diskmanage: fix determining array length
@ 2021-06-14 11:40 Fabian Ebner
  2021-06-15  8:10 ` [pve-devel] applied: " Thomas Lamprecht
  0 siblings, 1 reply; 2+ messages in thread
From: Fabian Ebner @ 2021-06-14 11:40 UTC (permalink / raw)
  To: pve-devel

$#* is the last index, not the length.

Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
---
 PVE/Diskmanage.pm | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/PVE/Diskmanage.pm b/PVE/Diskmanage.pm
index 55da2e5..ca6f0b7 100644
--- a/PVE/Diskmanage.pm
+++ b/PVE/Diskmanage.pm
@@ -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
-- 
2.30.2





^ permalink raw reply	[flat|nested] 2+ messages in thread

* [pve-devel] applied: [PATCH storage] diskmanage: fix determining array length
  2021-06-14 11:40 [pve-devel] [PATCH storage] diskmanage: fix determining array length Fabian Ebner
@ 2021-06-15  8:10 ` Thomas Lamprecht
  0 siblings, 0 replies; 2+ messages in thread
From: Thomas Lamprecht @ 2021-06-15  8:10 UTC (permalink / raw)
  To: Proxmox VE development discussion, Fabian Ebner

On 14.06.21 13:40, Fabian Ebner wrote:
> $#* is the last index, not the length.
> 
> Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
> ---
>  PVE/Diskmanage.pm | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
>

applied, thanks!




^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-06-15  8:10 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-06-14 11:40 [pve-devel] [PATCH storage] diskmanage: fix determining array length Fabian Ebner
2021-06-15  8:10 ` [pve-devel] applied: " Thomas Lamprecht

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.
Service provided by Proxmox Server Solutions GmbH | Privacy | Legal