[gtk-vnc] connection: adapt to libgcrypt >= 1.6
- From: Fabiano Fidêncio <ffidencio src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk-vnc] connection: adapt to libgcrypt >= 1.6
- Date: Tue, 6 Jan 2015 10:40:04 +0000 (UTC)
commit 9da749d45ace038b4d27120a14403c891cc9f1df
Author: Fabiano Fidêncio <fidencio redhat com>
Date: Mon Jan 5 14:16:31 2015 +0100
connection: adapt to libgcrypt >= 1.6
From "gcrypt.h":
> NOTE: Since Libgcrypt 1.6 the thread callbacks are not anymore used.
> However we keep it to allow for some source code compatibility if used
> in the standard way.
src/vncconnection.c | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
---
diff --git a/src/vncconnection.c b/src/vncconnection.c
index 9ef01ce..ca4d239 100644
--- a/src/vncconnection.c
+++ b/src/vncconnection.c
@@ -1171,6 +1171,7 @@ static void vnc_connection_debug_gnutls_log(int level, const char* str) {
}
#endif
+#if !defined(GCRYPT_VERSION_NUMBER) || (GCRYPT_VERSION_NUMBER < 0x010600)
static int gvnc_tls_mutex_init (void **priv)
{ \
GMutex *lock = NULL;
@@ -1209,6 +1210,7 @@ static struct gcry_thread_cbs gvnc_thread_impl = {
gvnc_tls_mutex_unlock,
NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL
};
+#endif
static gboolean vnc_connection_tls_initialize(void)
@@ -1219,7 +1221,9 @@ static gboolean vnc_connection_tls_initialize(void)
return TRUE;
if (g_thread_supported()) {
+#if !defined(GCRYPT_VERSION_NUMBER) || (GCRYPT_VERSION_NUMBER < 0x010600)
gcry_control(GCRYCTL_SET_THREAD_CBS, &gvnc_thread_impl);
+#endif
gcry_check_version(NULL);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]