grke/burp — pull request #139 by ZungBang (2013-01-30 18:51:51+00:00)
Title: cleaned up some valgrind errors and memory leaks in client mode

The following command

valgrind --leak-check=full --track-origins=yes ./burp

is now almost clean - we still get a memory leak error in ``SSL_connect`` (``client.c:202``), and there's still reachable memory (allocated by OpenSSL) when ``burp`` exits.

Note that among the many (harmless) uninitialized locals that valgrind reported, lurked a genuine bug in ``restore_client.c`` (``overwrite_ok`` checked the wrong ``stat`` struct when considering a FIFO).

Server mode still needs to be checked, but it'll take a while.

Please review and pull.