]> Pileus Git - ~andy/gtk/commit
Fix uninitialized digest_len field, causing WebSocket handshake to g_assert.
authorC. Scott Ananian <cscott@cscott.net>
Fri, 11 Nov 2011 21:26:12 +0000 (16:26 -0500)
committerAlexander Larsson <alexl@redhat.com>
Mon, 14 Nov 2011 08:55:19 +0000 (09:55 +0100)
commit981efc90b41d52f9785bbff66a94ec71a9174940
treecba40eaa7b47561e501f2ab09f8d7e42d751391d
parente19cbd7a045935a63801bc853746b5225d7de426
Fix uninitialized digest_len field, causing WebSocket handshake to g_assert.

g_checksum_get_digest checks to ensure that the passed digest_len is long
enough to hold the digest, before setting it to the actual length of the
digest returned.  Digest_len is uninitialized in the code, so if you're
lucky it will be larger than 20 and everything will work fine.  If you're
unlucky, g_checksum_get_digest will return either -1 or some number less
than 20, and the g_assert(digest_len==20) will fail.
gdk/broadway/gdkdisplay-broadway.c