[Spice-devel] [PATCH v5 5/9] server/red_worker: handle_dev_input: reuse write_ready introduced for async
Alon Levy
alevy at redhat.com
Tue Jul 19 01:52:59 PDT 2011
---
server/red_worker.c | 12 ++++--------
1 files changed, 4 insertions(+), 8 deletions(-)
diff --git a/server/red_worker.c b/server/red_worker.c
index 5a8431a..06cd8e9 100644
--- a/server/red_worker.c
+++ b/server/red_worker.c
@@ -9706,6 +9706,10 @@ static void handle_dev_input(EventListener *listener, uint32_t events)
case RED_WORKER_MESSAGE_CREATE_PRIMARY_SURFACE:
case RED_WORKER_MESSAGE_DESTROY_PRIMARY_SURFACE:
case RED_WORKER_MESSAGE_DESTROY_SURFACE_WAIT:
+ case RED_WORKER_MESSAGE_RESET_CURSOR:
+ case RED_WORKER_MESSAGE_RESET_IMAGE_CACHE:
+ case RED_WORKER_MESSAGE_STOP:
+ case RED_WORKER_MESSAGE_LOADVM_COMMANDS:
write_ready = 1;
default:
break;
@@ -9738,13 +9742,9 @@ static void handle_dev_input(EventListener *listener, uint32_t events)
break;
case RED_WORKER_MESSAGE_RESET_CURSOR:
red_cursor_reset(worker);
- message = RED_WORKER_MESSAGE_READY;
- write_message(worker->channel, &message);
break;
case RED_WORKER_MESSAGE_RESET_IMAGE_CACHE:
image_cache_reset(&worker->image_cache);
- message = RED_WORKER_MESSAGE_READY;
- write_message(worker->channel, &message);
break;
case RED_WORKER_MESSAGE_DESTROY_SURFACE_WAIT_ASYNC:
case RED_WORKER_MESSAGE_DESTROY_SURFACE_WAIT:
@@ -9779,8 +9779,6 @@ static void handle_dev_input(EventListener *listener, uint32_t events)
case RED_WORKER_MESSAGE_STOP: {
red_printf("stop");
handle_dev_stop(worker);
- message = RED_WORKER_MESSAGE_READY;
- write_message(worker->channel, &message);
break;
}
case RED_WORKER_MESSAGE_START:
@@ -9906,8 +9904,6 @@ static void handle_dev_input(EventListener *listener, uint32_t events)
}
count--;
}
- message = RED_WORKER_MESSAGE_READY;
- write_message(worker->channel, &message);
break;
}
default:
--
1.7.6
More information about the Spice-devel
mailing list