diff -rup gtk-vnc-0.4.1.orig/src/vncconnection.c gtk-vnc-0.4.1.new/src/vncconnection.c --- gtk-vnc-0.4.1.orig/src/vncconnection.c 2010-07-14 11:28:15.000000000 +0100 +++ gtk-vnc-0.4.1.new/src/vncconnection.c 2010-08-06 10:12:27.621989062 +0100 @@ -4191,7 +4191,12 @@ static void vnc_connection_close(VncConn priv->name = NULL; } - g_free (priv->xmit_buffer); + if (priv->xmit_buffer) { + g_free(priv->xmit_buffer); + priv->xmit_buffer = NULL; + priv->xmit_buffer_size = 0; + priv->xmit_buffer_capacity = 0; + } if (priv->cred_username) { g_free(priv->cred_username); Only in gtk-vnc-0.4.1.new/src: vncconnection.c~