summaryrefslogtreecommitdiffstats
path: root/include/libssh/libssh.h
diff options
context:
space:
mode:
authorAndreas Schneider <mail@cynapses.org>2009-09-22 12:27:28 +0200
committerAndreas Schneider <mail@cynapses.org>2009-09-22 12:28:07 +0200
commit7de3122b423487c3f2127f0b0a44ed7c6735fbff (patch)
tree8b38f2a833e09789f4795c3aed6aba6a0a88af5a /include/libssh/libssh.h
parent88f4e9ea24257bfdce511272a65a8d0f7eab8b35 (diff)
downloadlibssh-7de3122b423487c3f2127f0b0a44ed7c6735fbff.tar.gz
libssh-7de3122b423487c3f2127f0b0a44ed7c6735fbff.tar.xz
libssh-7de3122b423487c3f2127f0b0a44ed7c6735fbff.zip
Added a userdata generic pointer to the log callback function.
Diffstat (limited to 'include/libssh/libssh.h')
-rw-r--r--include/libssh/libssh.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/include/libssh/libssh.h b/include/libssh/libssh.h
index 8da66a2..e708401 100644
--- a/include/libssh/libssh.h
+++ b/include/libssh/libssh.h
@@ -376,6 +376,9 @@ LIBSSH_API int channel_get_exit_status(ssh_channel channel);
typedef int (*ssh_auth_callback) (const char *prompt, char *buf, size_t len,
int echo, int verify, void *userdata);
+typedef void (*ssh_log_callback) (ssh_session session, int priority,
+ const char *message, void *userdata);
+
LIBSSH_API SSH_OPTIONS *ssh_options_new(void);
LIBSSH_API SSH_OPTIONS *ssh_options_copy(SSH_OPTIONS *opt);
LIBSSH_API void ssh_options_free(SSH_OPTIONS *opt);
@@ -396,7 +399,7 @@ LIBSSH_API int ssh_options_set_timeout(SSH_OPTIONS *opt, long seconds, long usec
LIBSSH_API int ssh_options_allow_ssh1(SSH_OPTIONS *opt, int allow);
LIBSSH_API int ssh_options_allow_ssh2(SSH_OPTIONS *opt, int allow);
LIBSSH_API int ssh_options_set_log_function(SSH_OPTIONS *opt,
- void (*callback)(const char *message, SSH_SESSION *session, int verbosity));
+ ssh_log_callback cb, void *userdata);
LIBSSH_API int ssh_options_set_log_verbosity(SSH_OPTIONS *opt, int verbosity);
LIBSSH_API int ssh_options_set_dsa_server_key(SSH_OPTIONS *opt, const char *dsakey);
LIBSSH_API int ssh_options_set_rsa_server_key(SSH_OPTIONS *opt, const char *rsakey);