httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From n..@apache.org
Subject svn commit: r344142 - /httpd/httpd/branches/2.2.x/modules/database/mod_dbd.c
Date Mon, 14 Nov 2005 15:07:03 GMT
Author: niq
Date: Mon Nov 14 07:07:00 2005
New Revision: 344142

URL: http://svn.apache.org/viewcvs?rev=344142&view=rev
Log:
ver-dependent potential memory-use bug in preparing statements

Modified:
    httpd/httpd/branches/2.2.x/modules/database/mod_dbd.c

Modified: httpd/httpd/branches/2.2.x/modules/database/mod_dbd.c
URL: http://svn.apache.org/viewcvs/httpd/httpd/branches/2.2.x/modules/database/mod_dbd.c?rev=344142&r1=344141&r2=344142&view=diff
==============================================================================
--- httpd/httpd/branches/2.2.x/modules/database/mod_dbd.c (original)
+++ httpd/httpd/branches/2.2.x/modules/database/mod_dbd.c Mon Nov 14 07:07:00 2005
@@ -198,10 +198,11 @@
 {
     dbd_prepared *p;
     apr_status_t ret = APR_SUCCESS;
-    apr_dbd_prepared_t *stmt = NULL;
+    apr_dbd_prepared_t *stmt;
     dbd->prepared = apr_hash_make(pool);
 
     for (p = svr->prepared; p; p = p->next) {
+        stmt = NULL;
         if (apr_dbd_prepare(dbd->driver, pool, dbd->handle, p->query,
                             p->label, &stmt) == 0) {
             apr_hash_set(dbd->prepared, p->label, APR_HASH_KEY_STRING, stmt);



Mime
View raw message