You've already forked mariadb-connector-c
mirror of
https://github.com/mariadb-corporation/mariadb-connector-c.git
synced 2025-08-07 02:42:49 +03:00
CONC-741: Check that MYSQL_STMT is not null
The code now again allows null MYSQL_STMT handles to be passed to mysql_stmt_close(). Added a sanity check test case that should guard against this happening in the future.
This commit is contained in:
@@ -129,7 +129,7 @@ static my_bool madb_have_pending_results(MYSQL_STMT *stmt)
|
||||
{
|
||||
LIST *li_stmt;
|
||||
|
||||
if (!stmt->mysql)
|
||||
if (!stmt || !stmt->mysql)
|
||||
return 0;
|
||||
|
||||
li_stmt= stmt->mysql->stmts;
|
||||
|
Reference in New Issue
Block a user