From 4c1bd4e76e0cdbb61b38e31d408fff86a3203433 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Benjamin=20D=C3=BCrholt?= Date: Fri, 10 Apr 2015 12:16:15 +0200 Subject: prevent segfault --- libvncserver/rfbssl_gnutls.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'libvncserver/rfbssl_gnutls.c') diff --git a/libvncserver/rfbssl_gnutls.c b/libvncserver/rfbssl_gnutls.c index cf60cdc..fb3a0e7 100644 --- a/libvncserver/rfbssl_gnutls.c +++ b/libvncserver/rfbssl_gnutls.c @@ -109,6 +109,8 @@ struct rfbssl_ctx *rfbssl_init_global(char *key, char *cert) gnutls_global_set_log_function(rfbssl_log_func); gnutls_global_set_log_level(1); gnutls_certificate_set_dh_params(ctx->x509_cred, ctx->dh_params); + //newly allocated memory should be initialized, at least where it is important + ctx->peekstart = ctx->peeklen = 0; return ctx; } -- cgit v1.2.1 From 97490d68b024d76f2ebb52d59ffb1e8acc399d5e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Benjamin=20D=C3=BCrholt?= Date: Mon, 13 Apr 2015 11:45:24 +0200 Subject: Changed C++ style comments to C ones --- libvncserver/rfbssl_gnutls.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'libvncserver/rfbssl_gnutls.c') diff --git a/libvncserver/rfbssl_gnutls.c b/libvncserver/rfbssl_gnutls.c index fb3a0e7..e58cdad 100644 --- a/libvncserver/rfbssl_gnutls.c +++ b/libvncserver/rfbssl_gnutls.c @@ -109,7 +109,7 @@ struct rfbssl_ctx *rfbssl_init_global(char *key, char *cert) gnutls_global_set_log_function(rfbssl_log_func); gnutls_global_set_log_level(1); gnutls_certificate_set_dh_params(ctx->x509_cred, ctx->dh_params); - //newly allocated memory should be initialized, at least where it is important + /* newly allocated memory should be initialized, at least where it is important */ ctx->peekstart = ctx->peeklen = 0; return ctx; } -- cgit v1.2.1