mysql_client_test memory leaks
Affects | Status | Importance | Assigned to | Milestone | ||
---|---|---|---|---|---|---|
Percona Server moved to https://jira.percona.com/projects/PS | Status tracked in 5.7 | |||||
5.5 |
Fix Released
|
Low
|
Laurynas Biveinis | |||
5.6 |
Invalid
|
Undecided
|
Unassigned | |||
5.7 |
Invalid
|
Undecided
|
Unassigned |
Bug Description
main.mysql_
Test ended at 2016-06-06 11:20:24
CURRENT_TEST: main.mysql_
mysqltest: At line 17: command "$MYSQL_CLIENT_TEST --getopt-
...
=======
==7686==ERROR: LeakSanitizer: detected memory leaks
Direct leak of 8199 byte(s) in 1 object(s) allocated from:
#0 0x7f47e7c8954a in malloc (/usr/lib/
#1 0x4d6a87 in my_malloc /home/laurynas/
#2 0x557217 in my_net_init /home/laurynas/
#3 0x47dd0a in mysql_real_connect /home/laurynas/
#4 0x42718b in test_bug42373 /home/laurynas/
#5 0x46a664 in main /home/laurynas/
#6 0x7f47e6f0482f in __libc_start_main (/lib/x86_
Direct leak of 8160 byte(s) in 1 object(s) allocated from:
#0 0x7f47e7c8954a in malloc (/usr/lib/
#1 0x4d6a87 in my_malloc /home/laurynas/
#2 0x4c5410 in alloc_root /home/laurynas/
#3 0x4788e3 in unpack_fields /home/laurynas/
#4 0x47a0c6 in cli_read_
#5 0x48e12a in execute /home/laurynas/
#6 0x490bae in cli_stmt_execute /home/laurynas/
#7 0x49467f in mysql_stmt_execute /home/laurynas/
#8 0x427468 in test_bug42373 /home/laurynas/
#9 0x46a664 in main /home/laurynas/
#10 0x7f47e6f0482f in __libc_start_main (/lib/x86_
Direct leak of 816 byte(s) in 1 object(s) allocated from:
#0 0x7f47e7c8954a in malloc (/usr/lib/
#1 0x4d6a87 in my_malloc /home/laurynas/
#2 0x48f26b in mysql_stmt_init /home/laurynas/
#3 0x45d5d7 in test_bug43560 /home/laurynas/
#4 0x46a664 in main /home/laurynas/
#5 0x7f47e6f0482f in __libc_start_main (/lib/x86_
Direct leak of 496 byte(s) in 1 object(s) allocated from:
#0 0x7f47e7c8954a in malloc (/usr/lib/
#1 0x4d6a87 in my_malloc /home/laurynas/
#2 0x4c2272 in vio_new /home/laurynas/
#3 0x47d15d in mysql_real_connect /home/laurynas/
#4 0x42718b in test_bug42373 /home/laurynas/
#5 0x46a664 in main /home/laurynas/
#6 0x7f47e6f0482f in __libc_start_main (/lib/x86_
Direct leak of 152 byte(s) in 1 object(s) allocated from:
#0 0x7f47e7c8954a in malloc (/usr/lib/
#1 0x4d6a87 in my_malloc /home/laurynas/
#2 0x48fdc6 in mysql_stmt_
#3 0x439b83 in test_wl4435_3 /home/laurynas/
#4 0x46a664 in main /home/laurynas/
#5 0x7f47e6f0482f in __libc_start_main (/lib/x86_
...
tags: | added: asan ci upstream |
The fix would be to backport
commit 640ff30e35c22a1 7bfc4a2cfbd8408 d0980000f1
Author: Tor Didriksen <email address hidden>
Date: Thu Nov 1 11:59:32 2012 +0100
Bug#14840488 VALGRIND ERRORS IN MYSQL_CLIENT_TEST
Add missing DBUG_RETURNs, otherwise the debug-stack gets messed up,
and _db_enter_ and _db_exit_ will access data outside the current stack frame.
Add some missing mysql_free_xx() mysql_close_xx() to fix memory leaks.
commit e5d2a53b783d9a0 b5240b21d21883b 66f036009b
Author: Tor Didriksen <email address hidden>
Date: Thu Nov 1 17:23:06 2012 +0100
Bug#14840488 VALGRIND ERRORS IN MYSQL_CLIENT_TEST
Add missing DBUG_RETURNs, otherwise the debug-stack gets messed up,
and _db_enter_ and _db_exit_ will access data outside the current stack frame.