diff options
Diffstat (limited to 'lib/gnutls_global.c')
-rw-r--r-- | lib/gnutls_global.c | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/lib/gnutls_global.c b/lib/gnutls_global.c index 1a59bdfc19..60656d62d3 100644 --- a/lib/gnutls_global.c +++ b/lib/gnutls_global.c @@ -33,6 +33,7 @@ #include <gnutls_extensions.h> /* for _gnutls_ext_init */ #include <gnutls_cryptodev.h> #include <locks.h> +#include <system.h> #include "sockets.h" #include "gettext.h" @@ -69,6 +70,22 @@ gnutls_global_set_log_function (gnutls_log_func log_func) } /** + * gnutls_global_set_time_function: + * @time_func: it's the system time function + * + * This is the function where you can override the default system + * time function. + * + * gnutls_time_func is of the form, + * time_t (*gnutls_time_func)( time*); + **/ +void +gnutls_global_set_time_function (gnutls_time_func time_func) +{ + gnutls_time = time_func; +} + +/** * gnutls_global_set_log_level: * @level: it's an integer from 0 to 9. * |