<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/cpython-git.git/Modules/_posixsubprocess.c, branch travis-macOS</title>
<subtitle>github.com: python/cpython.git
</subtitle>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/'/>
<entry>
<title>bpo-37951: Lift subprocess's fork() restriction (GH-15544)</title>
<updated>2019-08-27T21:36:56+00:00</updated>
<author>
<name>Christian Heimes</name>
<email>christian@python.org</email>
</author>
<published>2019-08-27T21:36:56+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=98d90f745d35d5d07bffcb46788b50e05eea56c6'/>
<id>98d90f745d35d5d07bffcb46788b50e05eea56c6</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>bpo-37337: Add _PyObject_CallMethodNoArgs() (GH-14267)</title>
<updated>2019-07-08T08:19:25+00:00</updated>
<author>
<name>Jeroen Demeyer</name>
<email>J.Demeyer@UGent.be</email>
</author>
<published>2019-07-08T08:19:25+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=762f93ff2efd6b7ef0177cad57939c0ab2002eac'/>
<id>762f93ff2efd6b7ef0177cad57939c0ab2002eac</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>bpo-35550: Fix incorrect Solaris define guards (GH-11275)</title>
<updated>2018-12-31T02:16:40+00:00</updated>
<author>
<name>Jakub Kulík</name>
<email>Kulikjak@gmail.com</email>
</author>
<published>2018-12-31T02:16:40+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=6f9bc72c79c3262e5d0f2c0e96b016477399cfb1'/>
<id>6f9bc72c79c3262e5d0f2c0e96b016477399cfb1</id>
<content type='text'>
Python source code uses on several places ifdef sun or defined(sun) without the underscores, which is not standard compliant and shouldn't be used.

Defines should check for __sun instead. Reference: http://nadeausoftware.com/articles/2012/01/c_c_tip_how_use_compiler_predefined_macros_detect_operating_system#Solaris

https://bugs.python.org/issue35550</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Python source code uses on several places ifdef sun or defined(sun) without the underscores, which is not standard compliant and shouldn't be used.

Defines should check for __sun instead. Reference: http://nadeausoftware.com/articles/2012/01/c_c_tip_how_use_compiler_predefined_macros_detect_operating_system#Solaris

https://bugs.python.org/issue35550</pre>
</div>
</content>
</entry>
<entry>
<title>bpo-35214: Add _Py_ prefix to MEMORY_SANITIZER def. (GH-10503)</title>
<updated>2018-11-13T06:01:22+00:00</updated>
<author>
<name>Gregory P. Smith</name>
<email>greg@krypto.org</email>
</author>
<published>2018-11-13T06:01:22+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=3015fb8ce4d25603434b9b44bb7effb98a481532'/>
<id>3015fb8ce4d25603434b9b44bb7effb98a481532</id>
<content type='text'>
Rename our new MEMORY_SANITIZER define to _Py_MEMORY_SANITIZER.
Project based C Preprocessor namespacing at its finest. :P</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Rename our new MEMORY_SANITIZER define to _Py_MEMORY_SANITIZER.
Project based C Preprocessor namespacing at its finest. :P</pre>
</div>
</content>
</entry>
<entry>
<title>bpo-35214: Initial clang MemorySanitizer support (GH-10479)</title>
<updated>2018-11-12T20:07:14+00:00</updated>
<author>
<name>Gregory P. Smith</name>
<email>greg@krypto.org</email>
</author>
<published>2018-11-12T20:07:14+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=1584a0081500d35dc93ff88e5836df35faf3e3e2'/>
<id>1584a0081500d35dc93ff88e5836df35faf3e3e2</id>
<content type='text'>
Adds configure flags for msan and ubsan builds to make it easier to enable.
These also encode the detail that address sanitizer and memory sanitizer
should disable pymalloc.

Define MEMORY_SANITIZER when appropriate at build time and adds workarounds
to existing code to mark things as initialized where the sanitizer is otherwise unable to
determine that.  This lets our build succeed under the memory sanitizer.  not all tests
pass without sanitizer failures yet but we're in pretty good shape after this.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Adds configure flags for msan and ubsan builds to make it easier to enable.
These also encode the detail that address sanitizer and memory sanitizer
should disable pymalloc.

Define MEMORY_SANITIZER when appropriate at build time and adds workarounds
to existing code to mark things as initialized where the sanitizer is otherwise unable to
determine that.  This lets our build succeed under the memory sanitizer.  not all tests
pass without sanitizer failures yet but we're in pretty good shape after this.</pre>
</div>
</content>
</entry>
<entry>
<title>bpo-34651: Only allow the main interpreter to fork. (gh-9279)</title>
<updated>2018-09-14T21:17:20+00:00</updated>
<author>
<name>Eric Snow</name>
<email>ericsnowcurrently@gmail.com</email>
</author>
<published>2018-09-14T21:17:20+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=5903296045b586b9cd1fce0b1e02caf896028d1d'/>
<id>5903296045b586b9cd1fce0b1e02caf896028d1d</id>
<content type='text'>
When os.fork() is called (on platforms that support it) all threads but the current one are destroyed in the child process. Consequently we must ensure that all but the associated interpreter are likewise destroyed. The main interpreter is critical for runtime operation, so we must ensure that fork only happens in the main interpreter.

https://bugs.python.org/issue34651</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
When os.fork() is called (on platforms that support it) all threads but the current one are destroyed in the child process. Consequently we must ensure that all but the associated interpreter are likewise destroyed. The main interpreter is critical for runtime operation, so we must ensure that fork only happens in the main interpreter.

https://bugs.python.org/issue34651</pre>
</div>
</content>
</entry>
<entry>
<title>bpo-34658: Fix rare subprocess prexec_fn fork error. (GH-9255)</title>
<updated>2018-09-13T11:30:10+00:00</updated>
<author>
<name>Gregory P. Smith</name>
<email>greg@krypto.org</email>
</author>
<published>2018-09-13T11:30:10+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=a20b6adb5a5880fd22c099961eb9f9787739cefe'/>
<id>a20b6adb5a5880fd22c099961eb9f9787739cefe</id>
<content type='text'>
[bpo-34658](https://www.bugs.python.org/issue34658): Fix a rare interpreter unhandled exception state SystemError only
seen when using subprocess with a preexec_fn while an after_parent handler has
been registered with os.register_at_fork and the fork system call fails.



https://bugs.python.org/issue34658</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
[bpo-34658](https://www.bugs.python.org/issue34658): Fix a rare interpreter unhandled exception state SystemError only
seen when using subprocess with a preexec_fn while an after_parent handler has
been registered with os.register_at_fork and the fork system call fails.



https://bugs.python.org/issue34658</pre>
</div>
</content>
</entry>
<entry>
<title>bpo-32270: Don't close stdin/out/err in pass_fds (GH-6242)</title>
<updated>2018-09-11T00:46:22+00:00</updated>
<author>
<name>Gregory P. Smith</name>
<email>greg@krypto.org</email>
</author>
<published>2018-09-11T00:46:22+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=ce34410b8b67f49d8275c05d51b3ead50cf97f48'/>
<id>ce34410b8b67f49d8275c05d51b3ead50cf97f48</id>
<content type='text'>
When subprocess.Popen() stdin= stdout= or stderr= handles are specified
and appear in pass_fds=, don't close the original fds after dup'ing them.

This implementation and unittest primarily came from @izbyshev (see the PR)

See also https://github.com/izbyshev/cpython/commit/b89b52f28490b69142d5c061604b3a3989cec66c

This also removes the old manual p2cread, c2pwrite, and errwrite closing logic
as inheritable flags and _close_open_fds takes care of that properly today without special treatment.

This code is within child_exec() where it is the only thread so there is no
race condition between the dup and _Py_set_inheritable_async_safe call.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
When subprocess.Popen() stdin= stdout= or stderr= handles are specified
and appear in pass_fds=, don't close the original fds after dup'ing them.

This implementation and unittest primarily came from @izbyshev (see the PR)

See also https://github.com/izbyshev/cpython/commit/b89b52f28490b69142d5c061604b3a3989cec66c

This also removes the old manual p2cread, c2pwrite, and errwrite closing logic
as inheritable flags and _close_open_fds takes care of that properly today without special treatment.

This code is within child_exec() where it is the only thread so there is no
race condition between the dup and _Py_set_inheritable_async_safe call.</pre>
</div>
</content>
</entry>
<entry>
<title>bpo-32844: Fix a subprocess misredirection of a low fd (GH5689)</title>
<updated>2018-03-26T19:49:35+00:00</updated>
<author>
<name>Alexey Izbyshev</name>
<email>izbyshev@users.noreply.github.com</email>
</author>
<published>2018-03-26T19:49:35+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=0e7144b064a19493a146af94175a087b3888c37b'/>
<id>0e7144b064a19493a146af94175a087b3888c37b</id>
<content type='text'>
bpo-32844: subprocess: Fix a potential misredirection of a low fd to stderr.

When redirecting, subprocess attempts to achieve the following state:
each fd to be redirected to is less than or equal to the fd
it is redirected from, which is necessary because redirection
occurs in the ascending order of destination descriptors.
It fails to do so in a couple of corner cases,
for example, if 1 is redirected to 2 and 0 is closed in the parent.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
bpo-32844: subprocess: Fix a potential misredirection of a low fd to stderr.

When redirecting, subprocess attempts to achieve the following state:
each fd to be redirected to is less than or equal to the fd
it is redirected from, which is necessary because redirection
occurs in the ascending order of destination descriptors.
It fails to do so in a couple of corner cases,
for example, if 1 is redirected to 2 and 0 is closed in the parent.</pre>
</div>
</content>
</entry>
<entry>
<title>bpo-32777: Fix _Py_set_inheritable async-safety in subprocess (GH-5560)</title>
<updated>2018-02-06T06:09:34+00:00</updated>
<author>
<name>Alexey Izbyshev</name>
<email>izbyshev@users.noreply.github.com</email>
</author>
<published>2018-02-06T06:09:34+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=c1e46e94de38a92f98736af9a42d89c3975a9919'/>
<id>c1e46e94de38a92f98736af9a42d89c3975a9919</id>
<content type='text'>
Fix a rare but potential pre-exec child process deadlock in subprocess on POSIX systems when marking file descriptors inheritable on exec in the child process.  This bug appears to have been introduced in 3.4 with the inheritable file descriptors support.

This also changes Python/fileutils.c `set_inheritable` to use the "slow" two `fcntl` syscall path instead of the "fast" single `ioctl` syscall path when asked to be async signal safe (by way of being asked not to raise exceptions).  `ioctl` is not a POSIX async-signal-safe approved function.

ref: http://pubs.opengroup.org/onlinepubs/9699919799/functions/V2_chap02.html</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Fix a rare but potential pre-exec child process deadlock in subprocess on POSIX systems when marking file descriptors inheritable on exec in the child process.  This bug appears to have been introduced in 3.4 with the inheritable file descriptors support.

This also changes Python/fileutils.c `set_inheritable` to use the "slow" two `fcntl` syscall path instead of the "fast" single `ioctl` syscall path when asked to be async signal safe (by way of being asked not to raise exceptions).  `ioctl` is not a POSIX async-signal-safe approved function.

ref: http://pubs.opengroup.org/onlinepubs/9699919799/functions/V2_chap02.html</pre>
</div>
</content>
</entry>
</feed>
