summaryrefslogtreecommitdiffstats
path: root/php/php-5.4.7-odbctimer.patch
diff options
context:
space:
mode:
authorRemi Collet <fedora@famillecollet.com>2014-09-02 17:45:01 +0200
committerRemi Collet <fedora@famillecollet.com>2014-09-02 17:45:01 +0200
commit03d502e571b375ffd276b192ecd5128306ab3ef1 (patch)
tree2d0ddcacaecc662ee5dd362a0120cecaaa754fbc /php/php-5.4.7-odbctimer.patch
parent2f81cc3673b7f31e71f40dc47c9242c4ea410869 (diff)
reorg repo
Diffstat (limited to 'php/php-5.4.7-odbctimer.patch')
-rw-r--r--php/php-5.4.7-odbctimer.patch58
1 files changed, 0 insertions, 58 deletions
diff --git a/php/php-5.4.7-odbctimer.patch b/php/php-5.4.7-odbctimer.patch
deleted file mode 100644
index 88c4da4..0000000
--- a/php/php-5.4.7-odbctimer.patch
+++ /dev/null
@@ -1,58 +0,0 @@
-From 657494235eafe048e9fa6a19dcdb3c73a0cbe6ec Mon Sep 17 00:00:00 2001
-From: Remi Collet <fedora@famillecollet.com>
-Date: Thu, 27 Sep 2012 13:45:32 +0200
-Subject: [PATCH] Fixed bug #63171, script hangs if odbc call during timeout
-
----
- ext/odbc/php_odbc.c | 21 ++++++++++++++-------
- 1 file changed, 14 insertions(+), 7 deletions(-)
-
-diff --git a/ext/odbc/php_odbc.c b/ext/odbc/php_odbc.c
-index 52d46b2..2169e65 100644
---- a/ext/odbc/php_odbc.c
-+++ b/ext/odbc/php_odbc.c
-@@ -431,7 +431,8 @@ static void _free_odbc_result(zend_rsrc_list_entry *rsrc TSRMLS_DC)
- efree(res->values);
- res->values = NULL;
- }
-- if (res->stmt) {
-+ /* If aborted via timer expiration, don't try to call any unixODBC function */
-+ if (res->stmt && !(PG(connection_status) & PHP_CONNECTION_TIMEOUT)) {
- #if defined(HAVE_SOLID) || defined(HAVE_SOLID_30) || defined(HAVE_SOLID_35)
- SQLTransact(res->conn_ptr->henv, res->conn_ptr->hdbc,
- (SQLUSMALLINT) SQL_COMMIT);
-@@ -484,9 +485,12 @@ static void _close_odbc_conn(zend_rsrc_list_entry *rsrc TSRMLS_DC)
- }
- }
-
-- safe_odbc_disconnect(conn->hdbc);
-- SQLFreeConnect(conn->hdbc);
-- SQLFreeEnv(conn->henv);
-+ /* If aborted via timer expiration, don't try to call any unixODBC function */
-+ if (!(PG(connection_status) & PHP_CONNECTION_TIMEOUT)) {
-+ safe_odbc_disconnect(conn->hdbc);
-+ SQLFreeConnect(conn->hdbc);
-+ SQLFreeEnv(conn->henv);
-+ }
- efree(conn);
- ODBCG(num_links)--;
- }
-@@ -512,9 +516,12 @@ static void _close_odbc_pconn(zend_rsrc_list_entry *rsrc TSRMLS_DC)
- }
- }
-
-- safe_odbc_disconnect(conn->hdbc);
-- SQLFreeConnect(conn->hdbc);
-- SQLFreeEnv(conn->henv);
-+ /* If aborted via timer expiration, don't try to call any unixODBC function */
-+ if (!(PG(connection_status) & PHP_CONNECTION_TIMEOUT)) {
-+ safe_odbc_disconnect(conn->hdbc);
-+ SQLFreeConnect(conn->hdbc);
-+ SQLFreeEnv(conn->henv);
-+ }
- free(conn);
-
- ODBCG(num_links)--;
---
-1.7.10
-