Treat only StatusError as error, not StatusContinue

This commit is contained in:
Yuriy Taraday 2018-02-25 22:35:22 +04:00
parent 07dbf8603a
commit bfac3da6dc

2
rpc.go
View File

@ -365,7 +365,7 @@ func (l *Libvirt) sendPacket(serial uint32, proc uint32, program uint32, payload
func (l *Libvirt) getResponse(c chan response) (response, error) { func (l *Libvirt) getResponse(c chan response) (response, error) {
resp := <-c resp := <-c
if resp.Status != StatusOK { if resp.Status == StatusError {
return resp, decodeError(resp.Payload) return resp, decodeError(resp.Payload)
} }