diff options
author | Antony Dovgal <tony2001@php.net> | 2005-06-13 09:30:49 +0000 |
---|---|---|
committer | Antony Dovgal <tony2001@php.net> | 2005-06-13 09:30:49 +0000 |
commit | 2a128504a2d46a37e5c392eb8548f439273a34e6 (patch) | |
tree | 7bec1e8be444b8cfd97f3a9f62f64b9502c75bb0 /ext/oci8/oci8.c | |
parent | 54d85cbfdadeca491478e3894707534e2c9ccd1f (diff) | |
download | php-git-2a128504a2d46a37e5c392eb8548f439273a34e6.tar.gz |
destroy session after destroying error handle
SQLT_CHR is allowed too
Diffstat (limited to 'ext/oci8/oci8.c')
-rw-r--r-- | ext/oci8/oci8.c | 20 |
1 files changed, 11 insertions, 9 deletions
diff --git a/ext/oci8/oci8.c b/ext/oci8/oci8.c index 8921cc1496..9ddbe77e00 100644 --- a/ext/oci8/oci8.c +++ b/ext/oci8/oci8.c @@ -1015,6 +1015,15 @@ static void _oci_conn_list_dtor(oci_connection *connection TSRMLS_DC) ) ); } + + if (connection->pError) { + CALL_OCI( + OCIHandleFree( + (dvoid *) connection->pError, + (ub4) OCI_HTYPE_ERROR + ) + ); + } if (connection->session && connection->session->exclusive) { /* close associated session when destructed */ @@ -1026,15 +1035,6 @@ static void _oci_conn_list_dtor(oci_connection *connection TSRMLS_DC) efree(connection->descriptors); } - if (connection->pError) { - CALL_OCI( - OCIHandleFree( - (dvoid *) connection->pError, - (ub4) OCI_HTYPE_ERROR - ) - ); - } - oci_debug("END _oci_conn_list_dtor: id=%d",connection->id); efree(connection); @@ -3694,6 +3694,8 @@ break; } value_sz = sizeof(void*); break; + case SQLT_CHR: + break; default: php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unknown or unsupported datatype given: %u", ocitype); RETURN_FALSE; |