www.libssh2.org | Daily snapshots | Mailing list archive | Docs | Examples | github

Archive Index This month's Index

Subject: Re: memory leak in _libssh2_channel_open

Re: memory leak in _libssh2_channel_open

From: Henrik Nordström <henrik_at_henriknordstrom.net>
Date: Tue, 28 Feb 2012 11:09:26 +0100

mån 2012-02-27 klockan 21:17 -0700 skrev Steven Dake:

> I have found with my tracing patch I previously posted that the cause of
> the problem of the heavy leak was related to using the following api:
>
> libssh2_keepalive_config

Gah, keepalive again..

> If the code passes 1 in the want_reply parameter, the ssh server (fedora
> 16 opensshd) responds with a REQUEST_FAILURE (82) for every
> keepalive_send the code calls. I am not sure where the error is there,

It's the expected response. keep-alive is done using an unhandled
MSG_GLOBAL_REQUEST message.

> but I'd expect a REQUEST_FAILURE would result in no packet allocation in
> packet add. I haven't provided a patch as I'm not sure exactly what the
> solution should be.

Errors also need processing, but no one is eating the keepalive error
response.

Regards
Henrik

_______________________________________________
libssh2-devel http://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel
Received on 2012-02-28

the libssh2 team