]> git.proxmox.com Git - mirror_qemu.git/commitdiff
spice: remove only written event_mask field
authorFrediano Ziglio <fziglio@redhat.com>
Wed, 22 Nov 2017 13:56:24 +0000 (13:56 +0000)
committerGerd Hoffmann <kraxel@redhat.com>
Fri, 12 Jan 2018 13:35:58 +0000 (14:35 +0100)
Signed-off-by: Frediano Ziglio <fziglio@redhat.com>
Message-id: 20171122135625.16625-3-fziglio@redhat.com
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
ui/spice-core.c

index 85b9ea2127c8a62e622850f5b62437c1e38c4506..6d579faaaebf0357fa7e15427a42d43fdce7abd9 100644 (file)
@@ -89,7 +89,6 @@ static void timer_remove(SpiceTimer *timer)
 
 struct SpiceWatch {
     int fd;
-    int event_mask;
     SpiceWatchFunc func;
     void *opaque;
 };
@@ -111,11 +110,10 @@ static void watch_update_mask(SpiceWatch *watch, int event_mask)
     IOHandler *on_read = NULL;
     IOHandler *on_write = NULL;
 
-    watch->event_mask = event_mask;
-    if (watch->event_mask & SPICE_WATCH_EVENT_READ) {
+    if (event_mask & SPICE_WATCH_EVENT_READ) {
         on_read = watch_read;
     }
-    if (watch->event_mask & SPICE_WATCH_EVENT_WRITE) {
+    if (event_mask & SPICE_WATCH_EVENT_WRITE) {
         on_write = watch_write;
     }
     qemu_set_fd_handler(watch->fd, on_read, on_write, watch);