php-src/ext/pdo_odbc
Christoph M. Becker 08073b0658 Fix #79038: PDOStatement::nextRowset() leaks column values
Firstly, we must not rely on `stmt->column_count` when freeing the
driver specific column values, but rather store the column count in
the driver data.  Since the column count is a `short`, 16 bit are
sufficient, so we can store it in reserved bits of `pdo_odbc_stmt`.

Furthermore, we must not allocate new column value storage when the
statement is not executed, but rather when the column value storage has
not been allocated.

Finally, we have to introduce a driver specific `cursor_closer` to
avoid that `::closeCursor()` calls `odbc_stmt_next_rowset()` which then
frees the column value storage, because it may be still needed for
bound columns.
2020-02-17 22:53:02 +01:00
..
tests Sync leading and final newlines in *.phpt sections 2018-10-15 04:32:30 +02:00
config.m4 Fix minor Autoconf coding style 2018-07-31 03:09:44 +02:00
config.w32 Sync leading and final newlines in source code files 2018-10-14 12:55:24 +02:00
CREDITS
odbc_driver.c Remove unused Git attributes ident 2018-07-25 00:53:25 +02:00
odbc_stmt.c Fix #79038: PDOStatement::nextRowset() leaks column values 2020-02-17 22:53:02 +01:00
pdo_odbc.c Remove unused Git attributes ident 2018-07-25 00:53:25 +02:00
php_pdo_odbc_int.h Fix #79038: PDOStatement::nextRowset() leaks column values 2020-02-17 22:53:02 +01:00
php_pdo_odbc.h Remove unused Git attributes ident 2018-07-25 00:53:25 +02:00