[pve-devel] [PATCH] qemu-server : bridge_add : fix uninitialized value
Dietmar Maurer
dietmar at proxmox.com
Wed Jun 12 07:09:00 CEST 2013
applied,
> -----Original Message-----
> From: pve-devel-bounces at pve.proxmox.com [mailto:pve-devel-
> bounces at pve.proxmox.com] On Behalf Of Alexandre Derumier
> Sent: Dienstag, 11. Juni 2013 11:35
> To: pve-devel at pve.proxmox.com
> Subject: [pve-devel] [PATCH] qemu-server : bridge_add : fix uninitialized
> value
>
> fix : Use of uninitialized value $bridgeid in numeric lt (<) at
> /usr/share/perl5/PVE/QemuServer.pm line 2774.
>
> Signed-off-by: Alexandre Derumier <aderumier at odiso.com>
> ---
> PVE/QemuServer.pm | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/PVE/QemuServer.pm b/PVE/QemuServer.pm index
> a2ca048..d669d6b 100644
> --- a/PVE/QemuServer.pm
> +++ b/PVE/QemuServer.pm
> @@ -2771,7 +2771,7 @@ sub qemu_bridgeadd {
> while (my ($k, $v) = each %$bridges) {
> $bridgeid = $k;
> }
> - return if $bridgeid < 1;
> + return if !$bridgeid || $bridgeid < 1;
> my $bridge = "pci.$bridgeid";
> my $devices_list = vm_devices_list($vmid);
>
> --
> 1.7.10.4
>
> _______________________________________________
> pve-devel mailing list
> pve-devel at pve.proxmox.com
> http://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel
More information about the pve-devel
mailing list