bugfix: prevented endless loop in sendmsg

FS-8667 - some commands do not send a response with the type
command/reply but send api/response instead. check for this type,
too in order to prevent $client->comand() from never returning
to the users script.
This commit is contained in:
grindhold 2015-12-16 04:48:11 +01:00
parent 010db753f6
commit c61f6826c8
1 changed files with 2 additions and 1 deletions

View File

@ -145,7 +145,8 @@ sub sendmsg($$$) {
for(;;) {
$e = $self->readhash(undef);
last if $e->{socketerror} or $e->{'content-type'} eq 'command/reply';
last if $e->{socketerror} or $e->{'content-type'} eq 'command/reply'
or $e->{'content-type'} eq 'api/response';
push @{$self->{events}}, $e;
}