From ba4c3b070afca4f649f315a76017eac928a091e5 Mon Sep 17 00:00:00 2001 From: Luis Soares Date: Tue, 6 Jul 2010 23:41:59 +0100 Subject: [PATCH] BUG#54744: valgrind reports leak for mysqlbinlog The server was not cleaning up dbug allocated memory before exiting. This is not a real problem, as this memory would be deallocated anyway. Nonetheless, we improve the mysqlbinlog exit procedure, wrt to memory book-keeping, when no parameter is given. To fix this, we deploy a call to my_thread_end() before the thread exits, which will also free pending dbug related allocated blocks. --- client/mysqlbinlog.cc | 1 + 1 file changed, 1 insertion(+) diff --git a/client/mysqlbinlog.cc b/client/mysqlbinlog.cc index 9d85e24d03f..879409515c2 100644 --- a/client/mysqlbinlog.cc +++ b/client/mysqlbinlog.cc @@ -2032,6 +2032,7 @@ int main(int argc, char** argv) { usage(); free_defaults(defaults_argv); + my_thread_end(); exit(1); }