From 85f3ed4ab241e560a34e99e289784dd6483768db Mon Sep 17 00:00:00 2001
From: Tim Peters <tim.one@comcast.net>
Date: Fri, 6 May 2005 03:58:56 +0000
Subject: [PATCH] Merge rev 30262 from 3.4 branch.

`synchs` can be None -- deal with it.  Reported by Gary Poster.
---
 src/transaction/_manager.py | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/src/transaction/_manager.py b/src/transaction/_manager.py
index 94e3957d..2132df08 100644
--- a/src/transaction/_manager.py
+++ b/src/transaction/_manager.py
@@ -33,14 +33,15 @@ from transaction._transaction import Transaction
 # at top level here.
 
 # Call the ISynchronizer newTransaction() method on every element of
-# WeakSet synchs.
+# WeakSet synchs (or skip it if synchs is None).
 # A transaction manager needs to do this whenever begin() is called.
 # Since it would be good if tm.get() returned the new transaction while
 # newTransaction() is running, calling this has to be delayed until after
 # the transaction manager has done whatever it needs to do to make its
 # get() return the new txn.
 def _new_transaction(txn, synchs):
-    synchs.map(lambda s: s.newTransaction(txn))
+    if synchs:
+        synchs.map(lambda s: s.newTransaction(txn))
 
 class TransactionManager(object):
 
-- 
2.30.9