summaryrefslogtreecommitdiff
path: root/lib/state.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/state.c')
-rw-r--r--lib/state.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/lib/state.c b/lib/state.c
index f33cd5a8bc..a26c1c7a2f 100644
--- a/lib/state.c
+++ b/lib/state.c
@@ -1419,6 +1419,23 @@ gnutls_handshake_set_hook_function(gnutls_session_t session,
}
/**
+ * gnutls_handshake_set_read_function:
+ * @session: is #gnutls_session_t type
+ * @func: is the function to be called
+ *
+ * This function will set a callback to be called when a handshake
+ * message is being sent.
+ *
+ * Since: 3.6.13
+ */
+void
+gnutls_handshake_set_read_function(gnutls_session_t session,
+ gnutls_handshake_read_func func)
+{
+ session->internals.read_func = func;
+}
+
+/**
* gnutls_record_get_state:
* @session: is a #gnutls_session_t type
* @read: if non-zero the read parameters are returned, otherwise the write