Improve ssh_channel_new_id().

git-svn-id: svn+ssh://svn.berlios.de/svnroot/repos/libssh/trunk@672 7dcaeef0-15fb-0310-b436-a5af3365683c
This commit is contained in:
Andreas Schneider
2009-05-02 20:30:48 +00:00
parent 0b4159d1ec
commit f0b14c7b7a

View File

@@ -91,10 +91,17 @@ CHANNEL *channel_new(SSH_SESSION *session) {
return channel; return channel;
} }
u32 ssh_channel_new_id(SSH_SESSION *session){ /**
u32 ret=session->maxchannel; * @internal
session->maxchannel++; *
return ret; * @brief Create a new channel identifier.
*
* @param session The SSH session to use.
*
* @return The new channel identifier.
*/
u32 ssh_channel_new_id(SSH_SESSION *session) {
return ++(session->maxchannel);
} }
static int channel_open(CHANNEL *channel, const char *type_c, int window, static int channel_open(CHANNEL *channel, const char *type_c, int window,