1
0
mirror of https://github.com/MariaDB/server.git synced 2025-08-01 03:47:19 +03:00

MDEV-6262 analyze the coverity report on mariadb

uploaded 10.0, analyzed everything with the Impact=High
(and a couple of Medium)
This commit is contained in:
Sergei Golubchik
2017-05-17 15:16:24 +02:00
parent 335c4ab790
commit 7c03edf2fe
37 changed files with 96 additions and 63 deletions

View File

@ -7549,7 +7549,10 @@ QUICK_SELECT_I *TRP_ROR_UNION::make_quick(PARAM *param,
{
if (!(quick= (*scan)->make_quick(param, FALSE, &quick_roru->alloc)) ||
quick_roru->push_quick_back(quick))
{
delete quick_roru;
DBUG_RETURN(NULL);
}
}
quick_roru->records= records;
quick_roru->read_time= read_cost;
@ -11194,9 +11197,7 @@ QUICK_RANGE_SELECT *get_quick_select_for_ref(THD *thd, TABLE *table,
*/
thd->mem_root= old_root;
if (!quick || create_err)
return 0; /* no ranges found */
if (quick->init())
if (!quick || create_err || quick->init())
goto err;
quick->records= records;