Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
cpython
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
cpython
Commits
2ec82331
Kaydet (Commit)
2ec82331
authored
Kas 11, 2012
tarafından
Gregory P. Smith
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Fixes issue #14396: Handle the odd rare case of waitpid returning 0 when
not expected in subprocess.Popen.wait().
üst
9463e3ac
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
2 deletions
+9
-2
subprocess.py
Lib/subprocess.py
+6
-2
NEWS
Misc/NEWS
+3
-0
No files found.
Lib/subprocess.py
Dosyayı görüntüle @
2ec82331
...
@@ -1428,7 +1428,7 @@ class Popen(object):
...
@@ -1428,7 +1428,7 @@ class Popen(object):
def
wait
(
self
):
def
wait
(
self
):
"""Wait for child process to terminate. Returns returncode
"""Wait for child process to terminate. Returns returncode
attribute."""
attribute."""
if
self
.
returncode
is
None
:
while
self
.
returncode
is
None
:
try
:
try
:
pid
,
sts
=
_eintr_retry_call
(
os
.
waitpid
,
self
.
pid
,
0
)
pid
,
sts
=
_eintr_retry_call
(
os
.
waitpid
,
self
.
pid
,
0
)
except
OSError
as
e
:
except
OSError
as
e
:
...
@@ -1437,8 +1437,12 @@ class Popen(object):
...
@@ -1437,8 +1437,12 @@ class Popen(object):
# This happens if SIGCLD is set to be ignored or waiting
# This happens if SIGCLD is set to be ignored or waiting
# for child processes has otherwise been disabled for our
# for child processes has otherwise been disabled for our
# process. This child is dead, we can't get the status.
# process. This child is dead, we can't get the status.
pid
=
self
.
pid
sts
=
0
sts
=
0
self
.
_handle_exitstatus
(
sts
)
# Check the pid and loop as waitpid has been known to return
# 0 even without WNOHANG in odd situations. issue14396.
if
pid
==
self
.
pid
:
self
.
_handle_exitstatus
(
sts
)
return
self
.
returncode
return
self
.
returncode
...
...
Misc/NEWS
Dosyayı görüntüle @
2ec82331
...
@@ -10,6 +10,9 @@ What's New in Python 3.2.4
...
@@ -10,6 +10,9 @@ What's New in Python 3.2.4
Core and Builtins
Core and Builtins
-----------------
-----------------
- Issue #14396: Handle the odd rare case of waitpid returning 0 when not
expected in subprocess.Popen.wait().
- Issue #9535: Fix pending signals that have been received but not yet
- Issue #9535: Fix pending signals that have been received but not yet
handled by Python to not persist after os.fork() in the child process.
handled by Python to not persist after os.fork() in the child process.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment