From 70dd8b0348fc371c14c9525d33303d5ee84b1cd5 Mon Sep 17 00:00:00 2001 From: David Wedderwille Date: Thu, 13 Jun 2019 22:54:24 +0200 Subject: [PATCH] callbacks: Add ssh_threads_get_default() to the callbacks.h Fixes: T154 Signed-off-by: David Wedderwille Reviewed-by: Anderson Toshiyuki Sasaki Reviewed-by: Andreas Schneider --- include/libssh/callbacks.h | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/include/libssh/callbacks.h b/include/libssh/callbacks.h index 554527c7..15e88014 100644 --- a/include/libssh/callbacks.h +++ b/include/libssh/callbacks.h @@ -944,9 +944,20 @@ LIBSSH_API int ssh_threads_set_callbacks(struct ssh_threads_callbacks_struct *cb); /** - * @brief returns a pointer on the pthread threads callbacks, to be used with + * @brief Returns a pointer to the appropriate callbacks structure for the + * environment, to be used with ssh_threads_set_callbacks. + * + * @returns A pointer to a ssh_threads_callbacks_struct to be used with * ssh_threads_set_callbacks. - * @warning you have to link with the library ssh_threads. + * + * @see ssh_threads_set_callbacks + */ +LIBSSH_API struct ssh_threads_callbacks_struct *ssh_threads_get_default(void); + +/** + * @brief Returns a pointer on the pthread threads callbacks, to be used with + * ssh_threads_set_callbacks. + * * @see ssh_threads_set_callbacks */ LIBSSH_API struct ssh_threads_callbacks_struct *ssh_threads_get_pthread(void);