[Spice-devel,01/12] Bug fix: delete the reader entry after queueing an event, not before

Submitted by marcandre.lureau@redhat.com on Oct. 8, 2015, 3:40 p.m.

Details

Message ID 1444318841-16508-2-git-send-email-marcandre.lureau@redhat.com
State New
Headers show

Not browsing as part of any series.

Commit Message

marcandre.lureau@redhat.com Oct. 8, 2015, 3:40 p.m.
From: Jeremy White <jwhite@codeweavers.com>

As far as I can tell, the vreader_remove_reader function is not presently in
use anywhere; I have an upcoming patch set that uses it.

Signed-off-by: Jeremy White <jwhite@codeweavers.com>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
 src/vreader.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Patch hide | download patch | download mbox

diff --git a/src/vreader.c b/src/vreader.c
index 5029f76..bd662ac 100644
--- a/src/vreader.c
+++ b/src/vreader.c
@@ -533,8 +533,8 @@  vreader_remove_reader(VReader *reader)
     }
     vreader_dequeue(vreader_list, current_entry);
     vreader_list_unlock();
-    vreader_list_entry_delete(current_entry);
     vevent_queue_vevent(vevent_new(VEVENT_READER_REMOVE, reader, NULL));
+    vreader_list_entry_delete(current_entry);
     return VREADER_OK;
 }