You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@apr.apache.org by sf...@apache.org on 2012/08/05 23:06:59 UTC

svn commit: r1369681 - in /apr/apr/trunk/dbd: apr_dbd_freetds.c apr_dbd_mysql.c apr_dbd_pgsql.c apr_dbd_sqlite2.c

Author: sf
Date: Sun Aug  5 21:06:58 2012
New Revision: 1369681

URL: http://svn.apache.org/viewvc?rev=1369681&view=rev
Log:
Allow apr_dbd_get_row() to be called with a different pool than apr_dbd_select()

PR: 53533
Submitted by: <arthur echo gmail com>

Modified:
    apr/apr/trunk/dbd/apr_dbd_freetds.c
    apr/apr/trunk/dbd/apr_dbd_mysql.c
    apr/apr/trunk/dbd/apr_dbd_pgsql.c
    apr/apr/trunk/dbd/apr_dbd_sqlite2.c

Modified: apr/apr/trunk/dbd/apr_dbd_freetds.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/dbd/apr_dbd_freetds.c?rev=1369681&r1=1369680&r2=1369681&view=diff
==============================================================================
--- apr/apr/trunk/dbd/apr_dbd_freetds.c (original)
+++ apr/apr/trunk/dbd/apr_dbd_freetds.c Sun Aug  5 21:06:58 2012
@@ -327,7 +327,7 @@ static int dbd_freetds_get_row(apr_pool_
     case SUCCEED: return 0;
     case REG_ROW: return 0;
     case NO_MORE_ROWS:
-        apr_pool_cleanup_run(pool, res->proc, clear_result);
+        apr_pool_cleanup_run(res->pool, res->proc, clear_result);
         *rowp = NULL;
         return -1;
     case FAIL: return 1;

Modified: apr/apr/trunk/dbd/apr_dbd_mysql.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/dbd/apr_dbd_mysql.c?rev=1369681&r1=1369680&r2=1369681&view=diff
==============================================================================
--- apr/apr/trunk/dbd/apr_dbd_mysql.c (original)
+++ apr/apr/trunk/dbd/apr_dbd_mysql.c Sun Aug  5 21:06:58 2012
@@ -324,7 +324,7 @@ static int dbd_mysql_get_row(apr_pool_t 
         (*row)->len = mysql_fetch_lengths(res->res);
     }
     else {
-        apr_pool_cleanup_run(pool, res->res, free_result);
+        apr_pool_cleanup_run(res->pool, res->res, free_result);
     }
     return ret;
 }

Modified: apr/apr/trunk/dbd/apr_dbd_pgsql.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/dbd/apr_dbd_pgsql.c?rev=1369681&r1=1369680&r2=1369681&view=diff
==============================================================================
--- apr/apr/trunk/dbd/apr_dbd_pgsql.c (original)
+++ apr/apr/trunk/dbd/apr_dbd_pgsql.c Sun Aug  5 21:06:58 2012
@@ -264,7 +264,7 @@ static int dbd_pgsql_get_row(apr_pool_t 
     if (res->random) {
         if ((row->n >= 0) && (size_t)row->n >= res->ntuples) {
             *rowp = NULL;
-            apr_pool_cleanup_run(pool, res->res, clear_result);
+            apr_pool_cleanup_run(res->pool, res->res, clear_result);
             res->res = NULL;
             return -1;
         }

Modified: apr/apr/trunk/dbd/apr_dbd_sqlite2.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/dbd/apr_dbd_sqlite2.c?rev=1369681&r1=1369680&r2=1369681&view=diff
==============================================================================
--- apr/apr/trunk/dbd/apr_dbd_sqlite2.c (original)
+++ apr/apr/trunk/dbd/apr_dbd_sqlite2.c Sun Aug  5 21:06:58 2012
@@ -153,7 +153,7 @@ static int dbd_sqlite_get_row(apr_pool_t
 
     if (row->n >= res->ntuples) {
         *rowp = NULL;
-        apr_pool_cleanup_run(pool, res->res, free_table);
+        apr_pool_cleanup_run(res->pool, res->res, free_table);
         res->res = NULL;
         return -1;
     }