[3.14] gh-142195: Fixed Popen.communicate indefinite loops (GH-143203) by miss-islington · Pull Request #143255 · python/cpython

…43203)

Changed condition to evaluate if timeout is less than or equals to 0. This is needed for simulated time environments such as Shadow where the time will match exactly on the boundary.

---------
(cherry picked from commit fa9a425)

Co-authored-by: Prithviraj Chaudhuri <p.chaudhuri1993@gmail.com>
Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>

This was referenced

Dec 28, 2025