mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-08 18:23:57 -06:00
io: set correct error object in background reader test thread
The reader thread was accidentally setting the error pointer intended for the writer thread. If both threads set errors this would result in QEMU abort'ing due to the error already being set. Reviewed-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
This commit is contained in:
parent
a9d5aed12d
commit
256920eb94
1 changed files with 1 additions and 1 deletions
|
@ -132,7 +132,7 @@ static gpointer test_io_thread_reader(gpointer opaque)
|
|||
|
||||
if (ret == QIO_CHANNEL_ERR_BLOCK) {
|
||||
if (data->blocking) {
|
||||
error_setg(&data->writeerr,
|
||||
error_setg(&data->readerr,
|
||||
"Unexpected I/O blocking");
|
||||
break;
|
||||
} else {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue