add an assert to help debugging
This commit is contained in:
@@ -45,6 +45,7 @@
|
|||||||
#ifdef HAVE_INTTYPES_H
|
#ifdef HAVE_INTTYPES_H
|
||||||
#include <inttypes.h>
|
#include <inttypes.h>
|
||||||
#endif
|
#endif
|
||||||
|
#include <assert.h>
|
||||||
|
|
||||||
#include "channel.h"
|
#include "channel.h"
|
||||||
#include "transport.h"
|
#include "transport.h"
|
||||||
@@ -2435,6 +2436,8 @@ int _libssh2_channel_free(LIBSSH2_CHANNEL *channel)
|
|||||||
unsigned long data_len;
|
unsigned long data_len;
|
||||||
int rc;
|
int rc;
|
||||||
|
|
||||||
|
assert(session);
|
||||||
|
|
||||||
if (channel->free_state == libssh2_NB_state_idle) {
|
if (channel->free_state == libssh2_NB_state_idle) {
|
||||||
_libssh2_debug(session, LIBSSH2_DBG_CONN,
|
_libssh2_debug(session, LIBSSH2_DBG_CONN,
|
||||||
"Freeing channel %lu/%lu resources", channel->local.id,
|
"Freeing channel %lu/%lu resources", channel->local.id,
|
||||||
|
Reference in New Issue
Block a user