24#include <libssh/libssh.h>
25#include <libssh/callbacks.h>
30#define SSH_MUTEX pthread_mutex_t
32#if defined(PTHREAD_ERRORCHECK_MUTEX_INITIALIZER_NP)
33#define SSH_MUTEX_STATIC_INIT PTHREAD_ERRORCHECK_MUTEX_INITIALIZER_NP
35#define SSH_MUTEX_STATIC_INIT PTHREAD_MUTEX_INITIALIZER
38#elif (defined _WIN32) || (defined _WIN64)
42#define SSH_MUTEX CRITICAL_SECTION *
43#define SSH_MUTEX_STATIC_INIT NULL
47# define SSH_MUTEX void *
48#define SSH_MUTEX_STATIC_INIT NULL
56int ssh_threads_init(
void);
57void ssh_threads_finalize(
void);
58const char *ssh_threads_get_type(
void);
60void ssh_mutex_lock(SSH_MUTEX *mutex);
61void ssh_mutex_unlock(SSH_MUTEX *mutex);
64int crypto_thread_init(
struct ssh_threads_callbacks_struct *user_callbacks);
65void crypto_thread_finalize(
void);
struct ssh_threads_callbacks_struct * ssh_threads_get_default(void)
Returns a pointer to the appropriate callbacks structure for the environment, to be used with ssh_thr...
Definition noop.c:65