5
0
mirror of git://git.proxmox.com/git/qemu-server.git synced 2025-01-03 01:17:58 +03:00

avoid endless loop in QMPClient

This commit is contained in:
Dietmar Maurer 2013-04-18 10:34:44 +02:00
parent 393ee4a731
commit cbf183b6bf

View File

@ -254,6 +254,15 @@ sub queue_execute {
$self->{queue} = $self->{current} = $self->{fhs} = $self->{fhs_lookup} = {};
}
sub mux_close {
my ($self, $mux, $fh) = @_;
my $vmid = $self->{fhs_lookup}->{$fh} || 'undef';
return if !defined($vmid);
$self->{errors}->{$vmid} = "client closed connection\n" if !$self->{errors}->{$vmid};
}
# mux_input is called when input is available on one of
# the descriptors.
sub mux_input {