qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH v2] Fix crash when connecting to VNC through websocket
@ 2015-02-25 23:21 Jorge Acereda Maciá
  2015-02-26  6:38 ` Gerd Hoffmann
  0 siblings, 1 reply; 2+ messages in thread
From: Jorge Acereda Maciá @ 2015-02-25 23:21 UTC (permalink / raw)
  To: qemu-devel; +Cc: qemu-trivial, kraxel, aliguori


Connecting to VNC through websocket crashes in vnc_flush() when trying
to acquire a mutex that hasn't been initialized (vnc_init_state(vs)
hasn't been called at this point).

Signed-off-by: Jorge Acereda Macia <jacereda@gmail.com>

---
 ui/vnc-ws.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/ui/vnc-ws.c b/ui/vnc-ws.c
index e304baf..d75950d 100644
--- a/ui/vnc-ws.c
+++ b/ui/vnc-ws.c
@@ -207,8 +207,7 @@ static void vncws_send_handshake_response(VncState *vs, const char* key)
     }
 
     response = g_strdup_printf(WS_HANDSHAKE, accept);
-    vnc_write(vs, response, strlen(response));
-    vnc_flush(vs);
+    vnc_client_write_buf(vs, (const uint8_t *)response, strlen(response));
 
     g_free(accept);
     g_free(response);
-- 
1.9.3 (Apple Git-50)

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [Qemu-devel] [PATCH v2] Fix crash when connecting to VNC through websocket
  2015-02-25 23:21 [Qemu-devel] [PATCH v2] Fix crash when connecting to VNC through websocket Jorge Acereda Maciá
@ 2015-02-26  6:38 ` Gerd Hoffmann
  0 siblings, 0 replies; 2+ messages in thread
From: Gerd Hoffmann @ 2015-02-26  6:38 UTC (permalink / raw)
  To: Jorge Acereda Maciá; +Cc: qemu-trivial, qemu-devel, aliguori

On Do, 2015-02-26 at 00:21 +0100, Jorge Acereda Maciá wrote:
> Connecting to VNC through websocket crashes in vnc_flush() when trying
> to acquire a mutex that hasn't been initialized (vnc_init_state(vs)
> hasn't been called at this point).

Patch updated.

thanks,
  Gerd

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2015-02-26  6:38 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-02-25 23:21 [Qemu-devel] [PATCH v2] Fix crash when connecting to VNC through websocket Jorge Acereda Maciá
2015-02-26  6:38 ` Gerd Hoffmann

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).