mirror of
https://git.libssh.org/projects/libssh.git
synced 2026-02-07 02:39:48 +09:00
Reformat and initialize pointers
Signed-off-by: Jakub Jelen <jjelen@redhat.com> Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
This commit is contained in:
@@ -634,9 +634,10 @@ void ssh_set_fd_except(ssh_session session) {
|
||||
*
|
||||
* @return SSH_OK on success, SSH_ERROR otherwise.
|
||||
*/
|
||||
int ssh_handle_packets(ssh_session session, int timeout) {
|
||||
ssh_poll_handle spoll;
|
||||
ssh_poll_ctx ctx;
|
||||
int ssh_handle_packets(ssh_session session, int timeout)
|
||||
{
|
||||
ssh_poll_handle spoll = NULL;
|
||||
ssh_poll_ctx ctx = NULL;
|
||||
int tm = timeout;
|
||||
int rc;
|
||||
|
||||
@@ -654,11 +655,12 @@ int ssh_handle_packets(ssh_session session, int timeout) {
|
||||
}
|
||||
|
||||
if (timeout == SSH_TIMEOUT_USER) {
|
||||
if (ssh_is_blocking(session))
|
||||
tm = ssh_make_milliseconds(session->opts.timeout,
|
||||
session->opts.timeout_usec);
|
||||
else
|
||||
tm = 0;
|
||||
if (ssh_is_blocking(session)) {
|
||||
tm = ssh_make_milliseconds(session->opts.timeout,
|
||||
session->opts.timeout_usec);
|
||||
} else {
|
||||
tm = 0;
|
||||
}
|
||||
}
|
||||
rc = ssh_poll_ctx_dopoll(ctx, tm);
|
||||
if (rc == SSH_ERROR) {
|
||||
|
||||
Reference in New Issue
Block a user