]> git.proxmox.com Git - pve-ha-manager.git/commitdiff
check_active_workers: fix typo /uuid/uid/
authorThomas Lamprecht <t.lamprecht@proxmox.com>
Mon, 21 Dec 2015 09:12:47 +0000 (10:12 +0100)
committerDietmar Maurer <dietmar@proxmox.com>
Mon, 21 Dec 2015 09:21:01 +0000 (10:21 +0100)
This typo caused a bug where resource_command_finished was never
called as $w->{uuid} is not existing and thus always undefined.
Use the correct $w->{uid} instead.

Also fix a comment where used 'uuid' to avoid confusion.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
src/PVE/HA/LRM.pm

index dd735d1e57f3f48b9261f73a99bb4a819a454980..1fe5f67ecae7e04f0f7ac981450046f8a65ff700 100644 (file)
@@ -64,7 +64,7 @@ sub shutdown_request {
            my $sd = $ss->{$sid};
            next if !$sd->{node};
            next if $sd->{node} ne $nodename;
-           # Note: use undef uuid to mark shutdown/stop jobs
+           # Note: use undef uid to mark shutdown/stop jobs
            $self->queue_resource_command($sid, undef, 'request_stop');
        }
 
@@ -472,7 +472,7 @@ sub check_active_workers {
            # check status
            my $waitpid = waitpid($pid, WNOHANG);
            if (defined($waitpid) && ($waitpid == $pid)) {
-               if (defined($w->{uuid})) {
+               if (defined($w->{uid})) {
                    $self->resource_command_finished($sid, $w->{uid}, $?);
                } else {
                    $self->stop_command_finished($sid, $?);