diff options
author | Marko Mäkelä <marko.makela@mariadb.com> | 2020-03-25 12:09:47 +0200 |
---|---|---|
committer | Marko Mäkelä <marko.makela@mariadb.com> | 2020-03-25 12:09:47 +0200 |
commit | f01e7a4741bdf6da419c8a9a0676978b35cb02b4 (patch) | |
tree | 02c3aa4b2f219991f83faa12ae80c083e7fe1018 /client | |
parent | 9a7d284e202d8862a7b34aaf2253d4627177a90e (diff) | |
download | mariadb-git-f01e7a4741bdf6da419c8a9a0676978b35cb02b4.tar.gz |
MDEV-22035 Memory leak in main.mysqltestmariadb-10.5.2
The test main.mysqltest could crash or hang with
cmake -DWITH_ASAN=ON builds. The reason appears to be
a memory leak, which was found out by manually invoking
echo --replace_regex a > file
ASAN_OPTIONS=log_path=/dev/shm/asan mysqltest ... < file
and then examining the /dev/shm/asan.* file.
Diffstat (limited to 'client')
-rw-r--r-- | client/mysqltest.cc | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/client/mysqltest.cc b/client/mysqltest.cc index 3c878d4cb97..254020ba124 100644 --- a/client/mysqltest.cc +++ b/client/mysqltest.cc @@ -10265,6 +10265,7 @@ void append_replace_regex(char* expr, char *expr_end, struct st_replace_regex* r return; err: + my_free(res->regex_arr.buffer); my_free(res); die("Error parsing replace_regex \"%s\"", expr); } |