diff --git a/src/channel.c b/src/channel.c index 87126eeb..ed3032a7 100644 --- a/src/channel.c +++ b/src/channel.c @@ -2086,7 +2086,7 @@ ssize_t _libssh2_channel_read(LIBSSH2_CHANNEL *channel, int stream_id, /* expand the receiving window first if it has become too narrow */ if((channel->read_state == libssh2_NB_state_jump1) || (channel->remote.window_size < - channel->remote.window_size_initial / 4 * 3 + buflen) ) { + channel->remote.window_size_initial / 4 * 3 + buflen)) { uint32_t adjustment = (uint32_t)(channel->remote.window_size_initial + buflen - channel->remote.window_size); @@ -2737,7 +2737,7 @@ libssh2_channel_close(LIBSSH2_CHANNEL *channel) if(!channel) return LIBSSH2_ERROR_BAD_USE; - BLOCK_ADJUST(rc, channel->session, _libssh2_channel_close(channel) ); + BLOCK_ADJUST(rc, channel->session, _libssh2_channel_close(channel)); return rc; } diff --git a/src/pem.c b/src/pem.c index 94bcfae8..16717b73 100644 --- a/src/pem.c +++ b/src/pem.c @@ -528,7 +528,7 @@ _libssh2_openssh_pem_parse_data(LIBSSH2_SESSION * session, if(strcmp((const char *)kdfname, "bcrypt") == 0 && passphrase) { if((_libssh2_get_string(&kdf_buf, &salt, &salt_len)) || - (_libssh2_get_u32(&kdf_buf, &rounds) != 0) ) { + (_libssh2_get_u32(&kdf_buf, &rounds) != 0)) { ret = _libssh2_error(session, LIBSSH2_ERROR_PROTO, "kdf contains unexpected values"); LIBSSH2_FREE(session, key); diff --git a/src/session.c b/src/session.c index 3613d522..b1f31e90 100644 --- a/src/session.c +++ b/src/session.c @@ -812,7 +812,7 @@ libssh2_session_handshake(LIBSSH2_SESSION *session, libssh2_socket_t sock) { int rc; - BLOCK_ADJUST(rc, session, session_startup(session, sock) ); + BLOCK_ADJUST(rc, session, session_startup(session, sock)); return rc; } @@ -1107,7 +1107,7 @@ libssh2_session_free(LIBSSH2_SESSION * session) { int rc; - BLOCK_ADJUST(rc, session, session_free(session) ); + BLOCK_ADJUST(rc, session, session_free(session)); return rc; } diff --git a/src/session.h b/src/session.h index 0fab9de2..c88a4f53 100644 --- a/src/session.h +++ b/src/session.h @@ -41,9 +41,9 @@ /* Conveniance-macros to allow code like this; - int rc = BLOCK_ADJUST(rc, session, session_startup(session, sock) ); + int rc = BLOCK_ADJUST(rc, session, session_startup(session, sock)); - int rc = BLOCK_ADJUST_ERRNO(ptr, session, session_startup(session, sock) ); + int rc = BLOCK_ADJUST_ERRNO(ptr, session, session_startup(session, sock)); The point of course being to make sure that while in non-blocking mode these always return no matter what the return code is, but in blocking mode @@ -78,7 +78,7 @@ ptr = x; \ if(!sess->api_block_mode || \ (ptr != NULL) || \ - (libssh2_session_last_errno(sess) != LIBSSH2_ERROR_EAGAIN) ) \ + (libssh2_session_last_errno(sess) != LIBSSH2_ERROR_EAGAIN)) \ break; \ rc = _libssh2_wait_socket(sess, entry_time); \ } while(!rc); \ diff --git a/src/userauth.c b/src/userauth.c index e024bb00..40b64860 100644 --- a/src/userauth.c +++ b/src/userauth.c @@ -2158,7 +2158,7 @@ userauth_keyboard_interactive(LIBSSH2_SESSION * session, for(i = 0; i < session->userauth_kybd_num_prompts; i++) { /* string response[1] (ISO-10646 UTF-8) */ if(session->userauth_kybd_responses[i].length <= - (SIZE_MAX - 4 - session->userauth_kybd_packet_len) ) { + (SIZE_MAX - 4 - session->userauth_kybd_packet_len)) { session->userauth_kybd_packet_len += 4 + session->userauth_kybd_responses[i].length; }