virStreamAbort is needed when the caller wishes to terminate
the stream early, not when virStreamSend fails.
* qemu/qemu_driver.c: Fix calling of virStreamAbort during
tunnelled migration
for (;;) {
bytes = saferead(client_sock, buffer, sizeof(buffer));
if (bytes < 0) {
+ virStreamAbort(st);
virReportSystemError(dconn, errno, "%s",
_("tunnelled migration failed to read from qemu"));
goto close_client_sock;
if (virStreamSend(st, buffer, bytes) < 0) {
qemudReportError(dom->conn, dom, NULL, VIR_ERR_OPERATION_FAILED,
_("Failed to write migration data to remote libvirtd"));
- virStreamAbort(st);
goto close_client_sock;
}
}