File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -102,12 +102,22 @@ def test_nt_and_posix_stack_size(self):
102102 "size" )
103103
104104 fail_msg = "stack_size(%d) failed - should succeed"
105+ # 256 KiB may be below the sanitizer minimum (gh-141044 / TSan).
106+ tested = []
105107 for tss in (262144 , 0x100000 , 0 ):
106- thread .stack_size (tss )
108+ try :
109+ thread .stack_size (tss )
110+ except ValueError :
111+ verbose_print ("skipping stack_size(%d); below platform minimum"
112+ % tss )
113+ continue
107114 self .assertEqual (thread .stack_size (), tss , fail_msg % tss )
108115 verbose_print ("successfully set stack_size(%d)" % tss )
116+ tested .append (tss )
109117
110118 for tss in (262144 , 0x100000 ):
119+ if tss not in tested :
120+ continue
111121 verbose_print ("trying stack_size = (%d)" % tss )
112122 self .next_ident = 0
113123 self .created = 0
You can’t perform that action at this time.
0 commit comments