Testsuite for bsddb module, version 4.6.4
diff --git a/Lib/bsddb/dbshelve.py b/Lib/bsddb/dbshelve.py
index 96f604a..6d7414e 100644
--- a/Lib/bsddb/dbshelve.py
+++ b/Lib/bsddb/dbshelve.py
@@ -37,9 +37,18 @@
 #DictMixin was added
 if sys.version_info[:3] >= (2, 3, 0):
     HIGHEST_PROTOCOL = cPickle.HIGHEST_PROTOCOL
-    def _dumps(object, protocol):
-        return cPickle.dumps(object, protocol=protocol)
+# In python 2.3.*, "cPickle.dumps" accepts no
+# named parameters. "pickle.dumps" accepts them,
+# so this seems a bug.
+    if sys.version_info[:3] < (2, 4, 0):
+        def _dumps(object, protocol):
+            return cPickle.dumps(object, protocol)
+    else :
+        def _dumps(object, protocol):
+            return cPickle.dumps(object, protocol=protocol)
+
     from UserDict import DictMixin
+
 else:
     HIGHEST_PROTOCOL = None
     def _dumps(object, protocol):
@@ -133,7 +142,7 @@
 
 
     def keys(self, txn=None):
-        if txn is not None:
+        if txn != None:
             return self.db.keys(txn)
         else:
             return self.db.keys()
@@ -157,7 +166,7 @@
 
 
     def items(self, txn=None):
-        if txn is not None:
+        if txn != None:
             items = self.db.items(txn)
         else:
             items = self.db.items()
@@ -168,7 +177,7 @@
         return newitems
 
     def values(self, txn=None):
-        if txn is not None:
+        if txn != None:
             values = self.db.values(txn)
         else:
             values = self.db.values()