mirror of
https://github.com/libssh2/libssh2.git
synced 2025-10-31 23:30:25 +03:00
channel: Detect bad usage of libssh2_channel_process_startup
A common novice programmer error (at least among those using the wrapping Perl module Net::SSH2), is to try to reuse channels. This patchs detects that incorrect usage and fails with a LIBSSH2_ERROR_BAD_USE error instead of hanging. Signed-off-by: Salvador Fandino <sfandino-/E1597aS9LQAvxtiuMwx3w@public.gmane.org>
This commit is contained in:
committed by
Daniel Stenberg
parent
fc4a969a05
commit
fb432f3f78
@@ -216,7 +216,8 @@ typedef enum
|
||||
libssh2_NB_state_jump2,
|
||||
libssh2_NB_state_jump3,
|
||||
libssh2_NB_state_jump4,
|
||||
libssh2_NB_state_jump5
|
||||
libssh2_NB_state_jump5,
|
||||
libssh2_NB_state_end
|
||||
} libssh2_nonblocking_states;
|
||||
|
||||
typedef struct packet_require_state_t
|
||||
|
||||
Reference in New Issue
Block a user