[PATCH ustream] ustream-openssl: fix bio memory leak

Petr Štetiar ynezz at true.cz
Wed Dec 9 11:44:48 EST 2020


Eneas U de Queiroz <cotequeiroz at gmail.com> [2020-12-09 13:06:45]:

Hi,

> Using the patch by Pan Chen as inspiration, this avoids a memory leak by
> using a global BIO_METHOD pointer that doesn't ordinarily need to be
> freed.

this sounds weird, how is global pointer avoiding memory leaks? :-)

> CC: Pan Chen <serial115200 at outlook.com>
> 
> Signed-off-by: Eneas U de Queiroz <cotequeiroz at gmail.com>
> 
> ---
> Run-tested with a WRT-3200ACM, running uclient_fetch and uhttpd.
> I have not run it with valgrind or any other debugger.

how do you otherwise verify the correctness? :-) FYI this is my work in progress[1].

1. https://gitlab.com/ynezz/openwrt-ustream-ssl/-/commit/807ce1de752e021802a563783dfa580950746a0c

Cheers,

Petr



More information about the openwrt-devel mailing list