daemon: stream: Close stream on send failure

This is the only place in daemon/stream.c that sets
'stream->closed = true' but neglects to actually abort the stream
and remove the callback, which seems wrong.
This commit is contained in:
Cole Robinson 2016-04-25 13:15:48 -04:00
parent c48db92fbd
commit e7407872a4
1 changed files with 3 additions and 0 deletions

View File

@ -539,6 +539,9 @@ daemonStreamHandleWriteData(virNetServerClientPtr client,
VIR_INFO("Stream send failed");
stream->closed = true;
virStreamEventRemoveCallback(stream->st);
virStreamAbort(stream->st);
return virNetServerProgramSendReplyError(stream->prog,
client,
msg,