Commit 12b66b52 authored by Florent Xicluna's avatar Florent Xicluna

Closes #13140: Fix the daemon_threads attribute of ThreadingMixIn.

parent dcfde5aa
...@@ -588,8 +588,7 @@ class ThreadingMixIn: ...@@ -588,8 +588,7 @@ class ThreadingMixIn:
"""Start a new thread to process the request.""" """Start a new thread to process the request."""
t = threading.Thread(target = self.process_request_thread, t = threading.Thread(target = self.process_request_thread,
args = (request, client_address)) args = (request, client_address))
if self.daemon_threads: t.daemon = self.daemon_threads
t.daemon = True
t.start() t.start()
......
...@@ -123,7 +123,6 @@ class SocketServerTest(unittest.TestCase): ...@@ -123,7 +123,6 @@ class SocketServerTest(unittest.TestCase):
self.assertEqual(server.server_address, server.socket.getsockname()) self.assertEqual(server.server_address, server.socket.getsockname())
return server return server
@unittest.skipUnless(threading, 'Threading required for this test.')
@reap_threads @reap_threads
def run_server(self, svrcls, hdlrbase, testfunc): def run_server(self, svrcls, hdlrbase, testfunc):
server = self.make_server(self.pickaddr(svrcls.address_family), server = self.make_server(self.pickaddr(svrcls.address_family),
......
...@@ -66,6 +66,8 @@ Core and Builtins ...@@ -66,6 +66,8 @@ Core and Builtins
Library Library
------- -------
- Issue #13140: Fix the daemon_threads attribute of ThreadingMixIn.
- Issue #13339: Fix compile error in posixmodule.c due to missing semicolon. - Issue #13339: Fix compile error in posixmodule.c due to missing semicolon.
Thanks to Robert Xiao. Thanks to Robert Xiao.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment