Treat only StatusError as error, not StatusContinue
This commit is contained in:
parent
07dbf8603a
commit
bfac3da6dc
2
rpc.go
2
rpc.go
@ -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)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user