You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@apr.apache.org by tr...@apache.org on 2012/07/18 13:51:38 UTC
svn commit: r1362892 - /apr/apr/trunk/dbd/apr_dbd_freetds.c
Author: trawick
Date: Wed Jul 18 11:51:37 2012
New Revision: 1362892
URL: http://svn.apache.org/viewvc?rev=1362892&view=rev
Log:
APR dbd FreeTDS support: Fix spurious API errors caused by
unitialized fields.
Use apr_pcalloc instead of apr_palloc when allocating the dbd
structure so that all fields are initialized.
Submitted by: TROY.LIU 劉春偉 <TROY.LIU deltaww.com.cn>
Reviewed by: trawick
Modified:
apr/apr/trunk/dbd/apr_dbd_freetds.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=1362892&r1=1362891&r2=1362892&view=diff
==============================================================================
--- apr/apr/trunk/dbd/apr_dbd_freetds.c (original)
+++ apr/apr/trunk/dbd/apr_dbd_freetds.c Wed Jul 18 11:51:37 2012
@@ -627,7 +627,7 @@ static apr_dbd_t *dbd_freetds_open(apr_p
if (process == NULL) {
return NULL;
}
- sql = apr_palloc (pool, sizeof (apr_dbd_t));
+ sql = apr_pcalloc(pool, sizeof (apr_dbd_t));
sql->pool = pool;
sql->proc = process;
sql->params = params;