Skip to content

Commit

Permalink
Fixed memory leak.
Browse files Browse the repository at this point in the history
  • Loading branch information
Ilia Alshanetsky committed Aug 3, 2005
1 parent 23e671a commit ecc34bd
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions ext/pdo/pdo_stmt.c
Original file line number Diff line number Diff line change
Expand Up @@ -1994,6 +1994,10 @@ static void free_statement(pdo_stmt_t *stmt TSRMLS_DC)
stmt->columns = NULL;
}

if (stmt->fetch.into && stmt->default_fetch_type == PDO_FETCH_INTO) {
FREE_ZVAL(stmt->fetch.into);
stmt->fetch.into = NULL;
}

do_fetch_opt_finish(stmt, 1 TSRMLS_CC);

Expand Down

0 comments on commit ecc34bd

Please sign in to comment.