mirror of
https://git.libssh.org/projects/libssh.git
synced 2026-02-11 18:50:28 +09:00
channels: Reformat ssh_channel_free()
Signed-off-by: Andreas Schneider <asn@cryptomilk.org>
This commit is contained in:
@@ -1003,7 +1003,8 @@ error:
|
||||
*
|
||||
* @warning Any data unread on this channel will be lost.
|
||||
*/
|
||||
void ssh_channel_free(ssh_channel channel) {
|
||||
void ssh_channel_free(ssh_channel channel)
|
||||
{
|
||||
ssh_session session;
|
||||
|
||||
if (channel == NULL) {
|
||||
@@ -1021,8 +1022,8 @@ void ssh_channel_free(ssh_channel channel) {
|
||||
* We definitively close the channel when we receive a close message *and*
|
||||
* the user closed it.
|
||||
*/
|
||||
if((channel->flags & SSH_CHANNEL_FLAG_CLOSED_REMOTE)
|
||||
|| (channel->flags & SSH_CHANNEL_FLAG_NOT_BOUND)){
|
||||
if ((channel->flags & SSH_CHANNEL_FLAG_CLOSED_REMOTE) ||
|
||||
(channel->flags & SSH_CHANNEL_FLAG_NOT_BOUND)) {
|
||||
ssh_channel_do_free(channel);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user