diff options
author | Davide \"FunkyAss\" Del Zompo <davide.delzompo@gmail.com> | 2014-12-01 19:33:27 +0100 |
---|---|---|
committer | Andreas Schneider <asn@cryptomilk.org> | 2014-12-05 11:09:34 +0100 |
commit | df3d53e5610b5ccba00e56b96d93ddb3f50c85bf (patch) | |
tree | bc502dc0f628682079a18700d63583776b7723c5 | |
parent | f28c3099dac009fc37075cb4ae0faef9e30e9406 (diff) | |
download | libssh-df3d53e5610b5ccba00e56b96d93ddb3f50c85bf.tar.gz libssh-df3d53e5610b5ccba00e56b96d93ddb3f50c85bf.tar.xz libssh-df3d53e5610b5ccba00e56b96d93ddb3f50c85bf.zip |
doc: clarify tutorial error section
Signed-off-by: Davide "FunkyAss" Del Zompo <davide.delzompo@gmail.com>
Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
(cherry picked from commit bb197de75dc283eb0047e16f107c2441e957ea4f)
-rw-r--r-- | doc/guided_tour.dox | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/doc/guided_tour.dox b/doc/guided_tour.dox index 2fa906e0..ecd637e1 100644 --- a/doc/guided_tour.dox +++ b/doc/guided_tour.dox @@ -443,11 +443,10 @@ Most of time, the error returned are SSH_FATAL, but some functions (generaly the ssh_request_xxx ones) may fail because of server denying request. In these cases, SSH_REQUEST_DENIED is returned. -ssh_get_error() and ssh_get_error_code() take a ssh_session as a parameter. -That's for thread safety, error messages that can be attached to a session -aren't static anymore. Any error that happens during ssh_options_xxx() -or ssh_connect() (i.e., outside of any session) can be retrieved by -giving NULL as argument. +For thread safety, errors are bound to ssh_session objects. +As long as your ssh_session object is not NULL, you can retrieve the last error +message and error code from the ssh_session using ssh_get_error() and +ssh_get_error_code() respectively. The SFTP subsystem has its own error codes, in addition to libssh ones. |