channel: variable type cleanups
This commit is contained in:
parent
c3bcdd88a4
commit
13caffa00e
@ -56,10 +56,10 @@
|
|||||||
*
|
*
|
||||||
* Determine the next channel ID we can use at our end
|
* Determine the next channel ID we can use at our end
|
||||||
*/
|
*/
|
||||||
unsigned long
|
uint32_t
|
||||||
_libssh2_channel_nextid(LIBSSH2_SESSION * session)
|
_libssh2_channel_nextid(LIBSSH2_SESSION * session)
|
||||||
{
|
{
|
||||||
unsigned long id = session->next_channel;
|
uint32_t id = session->next_channel;
|
||||||
LIBSSH2_CHANNEL *channel;
|
LIBSSH2_CHANNEL *channel;
|
||||||
|
|
||||||
channel = _libssh2_list_first(&session->channels);
|
channel = _libssh2_list_first(&session->channels);
|
||||||
@ -90,7 +90,7 @@ _libssh2_channel_nextid(LIBSSH2_SESSION * session)
|
|||||||
* Locate a channel pointer by number
|
* Locate a channel pointer by number
|
||||||
*/
|
*/
|
||||||
LIBSSH2_CHANNEL *
|
LIBSSH2_CHANNEL *
|
||||||
_libssh2_channel_locate(LIBSSH2_SESSION *session, unsigned long channel_id)
|
_libssh2_channel_locate(LIBSSH2_SESSION *session, uint32_t channel_id)
|
||||||
{
|
{
|
||||||
LIBSSH2_CHANNEL *channel;
|
LIBSSH2_CHANNEL *channel;
|
||||||
LIBSSH2_LISTENER *l;
|
LIBSSH2_LISTENER *l;
|
||||||
@ -125,8 +125,9 @@ _libssh2_channel_locate(LIBSSH2_SESSION *session, unsigned long channel_id)
|
|||||||
*/
|
*/
|
||||||
LIBSSH2_CHANNEL *
|
LIBSSH2_CHANNEL *
|
||||||
_libssh2_channel_open(LIBSSH2_SESSION * session, const char *channel_type,
|
_libssh2_channel_open(LIBSSH2_SESSION * session, const char *channel_type,
|
||||||
unsigned int channel_type_len,
|
uint32_t channel_type_len,
|
||||||
unsigned int window_size, unsigned int packet_size,
|
uint32_t window_size,
|
||||||
|
uint32_t packet_size,
|
||||||
const char *message, unsigned int message_len)
|
const char *message, unsigned int message_len)
|
||||||
{
|
{
|
||||||
static const unsigned char reply_codes[3] = {
|
static const unsigned char reply_codes[3] = {
|
||||||
@ -1780,7 +1781,7 @@ libssh2_channel_read_ex(LIBSSH2_CHANNEL *channel, int stream_id, char *buf,
|
|||||||
* Return the size of the data block of the current packet, or 0 if there
|
* Return the size of the data block of the current packet, or 0 if there
|
||||||
* isn't a packet.
|
* isn't a packet.
|
||||||
*/
|
*/
|
||||||
unsigned long
|
size_t
|
||||||
_libssh2_channel_packet_data_len(LIBSSH2_CHANNEL * channel, int stream_id)
|
_libssh2_channel_packet_data_len(LIBSSH2_CHANNEL * channel, int stream_id)
|
||||||
{
|
{
|
||||||
LIBSSH2_SESSION *session = channel->session;
|
LIBSSH2_SESSION *session = channel->session;
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
#ifndef __LIBSSH2_CHANNEL_H
|
#ifndef __LIBSSH2_CHANNEL_H
|
||||||
#define __LIBSSH2_CHANNEL_H
|
#define __LIBSSH2_CHANNEL_H
|
||||||
/* Copyright (c) 2008-2009 by Daniel Stenberg
|
/* Copyright (c) 2008-2010 by Daniel Stenberg
|
||||||
*
|
*
|
||||||
* All rights reserved.
|
* All rights reserved.
|
||||||
*
|
*
|
||||||
@ -116,5 +116,14 @@ _libssh2_channel_process_startup(LIBSSH2_CHANNEL *channel,
|
|||||||
*/
|
*/
|
||||||
ssize_t _libssh2_channel_read(LIBSSH2_CHANNEL *channel, int stream_id,
|
ssize_t _libssh2_channel_read(LIBSSH2_CHANNEL *channel, int stream_id,
|
||||||
char *buf, size_t buflen);
|
char *buf, size_t buflen);
|
||||||
|
|
||||||
|
uint32_t _libssh2_channel_nextid(LIBSSH2_SESSION * session);
|
||||||
|
|
||||||
|
LIBSSH2_CHANNEL *_libssh2_channel_locate(LIBSSH2_SESSION * session,
|
||||||
|
uint32_t channel_id);
|
||||||
|
|
||||||
|
size_t _libssh2_channel_packet_data_len(LIBSSH2_CHANNEL * channel,
|
||||||
|
int stream_id);
|
||||||
|
|
||||||
#endif /* __LIBSSH2_CHANNEL_H */
|
#endif /* __LIBSSH2_CHANNEL_H */
|
||||||
|
|
||||||
|
@ -1125,11 +1125,6 @@ int _libssh2_wait_socket(LIBSSH2_SESSION *session);
|
|||||||
|
|
||||||
int libssh2_kex_exchange(LIBSSH2_SESSION * session, int reexchange,
|
int libssh2_kex_exchange(LIBSSH2_SESSION * session, int reexchange,
|
||||||
key_exchange_state_t * state);
|
key_exchange_state_t * state);
|
||||||
unsigned long _libssh2_channel_nextid(LIBSSH2_SESSION * session);
|
|
||||||
LIBSSH2_CHANNEL *_libssh2_channel_locate(LIBSSH2_SESSION * session,
|
|
||||||
unsigned long channel_id);
|
|
||||||
unsigned long _libssh2_channel_packet_data_len(LIBSSH2_CHANNEL * channel,
|
|
||||||
int stream_id);
|
|
||||||
|
|
||||||
/* this is the lib-internal set blocking function */
|
/* this is the lib-internal set blocking function */
|
||||||
int _libssh2_session_set_blocking(LIBSSH2_SESSION * session, int blocking);
|
int _libssh2_session_set_blocking(LIBSSH2_SESSION * session, int blocking);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user