]> granicus.if.org Git - python/commitdiff
bug [ 1238170 ] threading.Thread uses {} as default argument
authorGeorg Brandl <georg@python.org>
Fri, 15 Jul 2005 09:13:21 +0000 (09:13 +0000)
committerGeorg Brandl <georg@python.org>
Fri, 15 Jul 2005 09:13:21 +0000 (09:13 +0000)
Lib/threading.py
Misc/NEWS

index cbcc1f91b280f8a06289d45626b12a55166c1391..fe4490fa3ac399a1318053577bde2fe723eb65dd 100644 (file)
@@ -374,9 +374,11 @@ class Thread(_Verbose):
     __exc_info = _sys.exc_info
 
     def __init__(self, group=None, target=None, name=None,
-                 args=(), kwargs={}, verbose=None):
+                 args=(), kwargs=None, verbose=None):
         assert group is None, "group argument must be None for now"
         _Verbose.__init__(self, verbose)
+        if kwargs is None:
+            kwargs = {}
         self.__target = target
         self.__name = str(name or _newname())
         self.__args = args
index 2c0207f04408c4005eacb69e1c08dc97ebd6b710..7c7c51dbbe359cd91946932984951e3242fa25bc 100644 (file)
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -168,6 +168,9 @@ Extension Modules
 Library
 -------
 
+- Bug #1238170: threading.Thread.__init__ no longer has "kwargs={}" as a
+  parameter, but uses the usual "kwargs=None".
+
 - textwrap now processes text chucks at O(n) speed instead of O(n**2).
   Patch #1209527 (Contributed by Connelly).