wasm32-emscripten does not support exceptfds and requires NULL. Python
now passes NULL instead of a fdset pointer when the input list is empty.
This works fine on all platforms and might even be a tiny bit faster.
self.assertIsNot(r, x)
self.assertIsNot(w, x)
- @unittest.skipUnless(hasattr(os, 'popen'), "need os.popen()")
+ @support.requires_fork()
def test_select(self):
code = textwrap.dedent('''
import time
--- /dev/null
+:func:`select.select` now passes ``NULL`` to ``select`` for each empty fdset.
do {
Py_BEGIN_ALLOW_THREADS
errno = 0;
- n = select(max, &ifdset, &ofdset, &efdset, tvp);
+ n = select(
+ max,
+ imax ? &ifdset : NULL,
+ omax ? &ofdset : NULL,
+ emax ? &efdset : NULL,
+ tvp);
Py_END_ALLOW_THREADS
if (errno != EINTR)