diff mbox

[1/2] postcopy: listen thread is never joined

Message ID 1457553016-1869-2-git-send-email-dgilbert@redhat.com
State New
Headers show

Commit Message

Dr. David Alan Gilbert March 9, 2016, 7:50 p.m. UTC
From: "Dr. David Alan Gilbert" <dgilbert@redhat.com>

We don't join the listen thread, it does it's own cleanup.
Mark as detached not joinable.

Signed-off-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
Reported-by: Paolo Bonzini <pbonzini@redhat.com>
---
 migration/savevm.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Eric Blake March 9, 2016, 8:11 p.m. UTC | #1
On 03/09/2016 12:50 PM, Dr. David Alan Gilbert (git) wrote:
> From: "Dr. David Alan Gilbert" <dgilbert@redhat.com>
> 
> We don't join the listen thread, it does it's own cleanup.

s/it's/its/

("it's" is appropriate only if "it is" can be dropped in its place;
otherwise you want the possessive "its").

> Mark as detached not joinable.
> 
> Signed-off-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
> Reported-by: Paolo Bonzini <pbonzini@redhat.com>
> ---
>  migration/savevm.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)

Reviewed-by: Eric Blake <eblake@redhat.com>
diff mbox

Patch

diff --git a/migration/savevm.c b/migration/savevm.c
index 384e872..0a33c22 100644
--- a/migration/savevm.c
+++ b/migration/savevm.c
@@ -1494,7 +1494,7 @@  static int loadvm_postcopy_handle_listen(MigrationIncomingState *mis)
     qemu_sem_init(&mis->listen_thread_sem, 0);
     qemu_thread_create(&mis->listen_thread, "postcopy/listen",
                        postcopy_ram_listen_thread, mis->from_src_file,
-                       QEMU_THREAD_JOINABLE);
+                       QEMU_THREAD_DETACHED);
     qemu_sem_wait(&mis->listen_thread_sem);
     qemu_sem_destroy(&mis->listen_thread_sem);