fix memory leak caused by pecalloced persistent connection; fix test indentation

This commit is contained in:
v-kaywon 2017-03-17 16:46:02 -07:00
parent b701fab642
commit c9492ae487
3 changed files with 26 additions and 25 deletions

View file

@ -433,6 +433,7 @@ int pdo_sqlsrv_db_handle_factory(pdo_dbh_t *dbh, zval *driver_options TSRMLS_DC)
}
// throws PDOException if the ATTR_PERSISTENT is in connection options
CHECK_CUSTOM_ERROR( dbh->is_persistent, *g_henv_cp, PDO_SQLSRV_ERROR_UNSUPPORTED_DBH_ATTR ) {
dbh->refcount--;
throw pdo::PDOException();
}