From d8a80a1cfca7c46df82a4c730fa74cb3ee463d20 Mon Sep 17 00:00:00 2001 From: Geoffrey McRae Date: Thu, 14 Dec 2017 10:08:47 +1100 Subject: [PATCH] [client] move startup later as DXGI stalls when nothing is going on --- client/main.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/client/main.c b/client/main.c index 427286a0..46ca6a80 100644 --- a/client/main.c +++ b/client/main.c @@ -745,15 +745,6 @@ int run() state.shmSize = ivshmem_get_map_size(); state.shm->hostID = ivshmem_get_id(); - // flag the host that we are starting up this is important so that - // the host wakes up if it is waiting on an interrupt, the host will - // also send us the current mouse shape since we won't know it yet - DEBUG_INFO("Waiting for host to signal it's ready..."); - __sync_or_and_fetch(&state.shm->flags, KVMFR_HEADER_FLAG_RESTART); - while(state.running && (state.shm->flags & KVMFR_HEADER_FLAG_RESTART)) - usleep(1000); - DEBUG_INFO("Host ready, starting session"); - if (params.useSpice) { if (!spice_connect(params.spiceHost, params.spicePort, "")) @@ -783,6 +774,15 @@ int run() break; } + // flag the host that we are starting up this is important so that + // the host wakes up if it is waiting on an interrupt, the host will + // also send us the current mouse shape since we won't know it yet + DEBUG_INFO("Waiting for host to signal it's ready..."); + __sync_or_and_fetch(&state.shm->flags, KVMFR_HEADER_FLAG_RESTART); + while(state.running && (state.shm->flags & KVMFR_HEADER_FLAG_RESTART)) + usleep(1000); + DEBUG_INFO("Host ready, starting session"); + while(state.running) renderThread(NULL);