summaryrefslogtreecommitdiffstats
path: root/Modules
diff options
context:
space:
mode:
authorNeal Norwitz <nnorwitz@gmail.com>2007-05-19 04:37:31 (GMT)
committerNeal Norwitz <nnorwitz@gmail.com>2007-05-19 04:37:31 (GMT)
commit73bf1018d654553bf659dfa6f4608875f89ca2c0 (patch)
treea898c35ae8814ea347f3f3d3b625c40097f7b9c1 /Modules
parentf86ae691d34285e9c98ffb52d513aad1b61129c4 (diff)
downloadcpython-73bf1018d654553bf659dfa6f4608875f89ca2c0.zip
cpython-73bf1018d654553bf659dfa6f4608875f89ca2c0.tar.gz
cpython-73bf1018d654553bf659dfa6f4608875f89ca2c0.tar.bz2
Backport rev 55452:
Whoops, need to pay attention to those test failures. Move the clear to *before* the first use, not after.
Diffstat (limited to 'Modules')
-rw-r--r--Modules/_bsddb.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Modules/_bsddb.c b/Modules/_bsddb.c
index f064878..e7613fb 100644
--- a/Modules/_bsddb.c
+++ b/Modules/_bsddb.c
@@ -1706,6 +1706,7 @@ DB_get_both(DBObject* self, PyObject* args, PyObject* kwargs)
CHECK_DB_NOT_CLOSED(self);
if (!make_key_dbt(self, keyobj, &key, NULL))
return NULL;
+ CLEAR_DBT(data);
if ( !make_dbt(dataobj, &data) ||
!checkTxnObj(txnobj, &txn) )
{
@@ -1713,7 +1714,6 @@ DB_get_both(DBObject* self, PyObject* args, PyObject* kwargs)
return NULL;
}
- CLEAR_DBT(data);
flags |= DB_GET_BOTH;
if (CHECK_DBFLAG(self, DB_THREAD)) {