Fix thinko in new ECPG "PREPARE AS" code.
ecpg_register_prepared_stmt() is pretty obviously checking the wrong
variable while trying to detect malloc failure. Error in commit
a1dc6ab46
, spotted by Coverity.
This commit is contained in:
parent
9679345f3c
commit
331695a4d9
|
@ -85,7 +85,7 @@ ecpg_register_prepared_stmt(struct statement *stmt)
|
|||
return false;
|
||||
|
||||
prep_stmt = (struct statement *) ecpg_alloc(sizeof(struct statement), lineno);
|
||||
if (!stmt)
|
||||
if (!prep_stmt)
|
||||
{
|
||||
ecpg_free(this);
|
||||
return false;
|
||||
|
|
Loading…
Reference in New Issue