mirror of
https://github.com/php/php-src.git
synced 2024-09-22 18:37:25 +00:00
add sanity checks
This commit is contained in:
parent
a6f0d99e5b
commit
bf85bf515e
@ -1985,9 +1985,13 @@ static void free_statement(pdo_stmt_t *stmt TSRMLS_DC)
|
||||
struct pdo_column_data *cols = stmt->columns;
|
||||
|
||||
for (i = 0; i < stmt->column_count; i++) {
|
||||
efree(cols[i].name);
|
||||
if (cols[i].name) {
|
||||
efree(cols[i].name);
|
||||
cols[i].name = NULL;
|
||||
}
|
||||
}
|
||||
efree(stmt->columns);
|
||||
stmt->columns = NULL;
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user