summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorZoltan Fridrich <zfridric@redhat.com>2023-02-01 13:29:34 +0100
committerZoltan Fridrich <zfridric@redhat.com>2023-02-06 09:39:25 +0100
commit4a065f3fddf1cf77a531a90aec85a41293b009d2 (patch)
treeb41368a2dd50ff80275b53f8daf3e8e576795627 /src
parent1dc85222fc8e08a3fc9e6c554f001a44baa61bd0 (diff)
downloadgnutls-4a065f3fddf1cf77a531a90aec85a41293b009d2.tar.gz
socket: set pull/push functions on windows
Signed-off-by: Zoltan Fridrich <zfridric@redhat.com>
Diffstat (limited to 'src')
-rw-r--r--src/socket.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/socket.c b/src/socket.c
index 3a6993553e..953d63f767 100644
--- a/src/socket.c
+++ b/src/socket.c
@@ -613,7 +613,17 @@ socket_open2(socket_st * hd, const char *hostname, const char *service,
(hd->session, wrap_pull_timeout_func);
gnutls_transport_set_ptr(hd->session, hd);
} else {
+#ifdef _WIN32
+ gnutls_transport_set_push_function(hd->session,
+ wrap_push);
+ gnutls_transport_set_pull_function(hd->session,
+ wrap_pull);
+ gnutls_transport_set_pull_timeout_function
+ (hd->session, wrap_pull_timeout_func);
+ gnutls_transport_set_ptr(hd->session, hd);
+#else
gnutls_transport_set_int(hd->session, hd->fd);
+#endif
}
}