File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -4330,6 +4330,9 @@ def test_closefd(self):
4330
4330
4331
4331
class TestIgnoreEINTR (unittest .TestCase ):
4332
4332
4333
+ # Sending CONN_MAX_SIZE bytes into a multiprocessing pipe must block
4334
+ CONN_MAX_SIZE = max (support .PIPE_MAX_SIZE , support .SOCK_MAX_SIZE )
4335
+
4333
4336
@classmethod
4334
4337
def _test_ignore (cls , conn ):
4335
4338
def handler (signum , frame ):
@@ -4338,7 +4341,7 @@ def handler(signum, frame):
4338
4341
conn .send ('ready' )
4339
4342
x = conn .recv ()
4340
4343
conn .send (x )
4341
- conn .send_bytes (b'x' * support . PIPE_MAX_SIZE )
4344
+ conn .send_bytes (b'x' * cls . CONN_MAX_SIZE )
4342
4345
4343
4346
@unittest .skipUnless (hasattr (signal , 'SIGUSR1' ), 'requires SIGUSR1' )
4344
4347
def test_ignore (self ):
@@ -4357,7 +4360,7 @@ def test_ignore(self):
4357
4360
self .assertEqual (conn .recv (), 1234 )
4358
4361
time .sleep (0.1 )
4359
4362
os .kill (p .pid , signal .SIGUSR1 )
4360
- self .assertEqual (conn .recv_bytes (), b'x' * support . PIPE_MAX_SIZE )
4363
+ self .assertEqual (conn .recv_bytes (), b'x' * self . CONN_MAX_SIZE )
4361
4364
time .sleep (0.1 )
4362
4365
p .join ()
4363
4366
finally :
You can’t perform that action at this time.
0 commit comments