<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/cpython-git.git/Modules/socketmodule.c, branch fix-misc-acks</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-37811: FreeBSD, OSX: fix poll(2) usage in sockets module (GH-15202)</title>
<updated>2019-08-14T21:48:03+00:00</updated>
<author>
<name>Miss Islington (bot)</name>
<email>31488909+miss-islington@users.noreply.github.com</email>
</author>
<published>2019-08-14T21:48:03+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=b0b178a2b80974da910ce6a344d66cc4d9a2fcfa'/>
<id>b0b178a2b80974da910ce6a344d66cc4d9a2fcfa</id>
<content type='text'>
FreeBSD implementation of poll(2) restricts the timeout argument to be
either zero, or positive, or equal to INFTIM (-1).

Unless otherwise overridden, socket timeout defaults to -1. This value
is then converted to milliseconds (-1000) and used as argument to the
poll syscall. poll returns EINVAL (22), and the connection fails.

This bug was discovered during the EINTR handling testing, and the
reproduction code can be found in
https://bugs.python.org/issue23618 (see connect_eintr.py,
attached). On GNU/Linux, the example runs as expected.

This change is trivial:
If the supplied timeout value is negative, truncate it to -1.
(cherry picked from commit 28146206578ebe1b84b48e6f255738a227058c04)

Co-authored-by: Artem Khramov &lt;akhramov@pm.me&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
FreeBSD implementation of poll(2) restricts the timeout argument to be
either zero, or positive, or equal to INFTIM (-1).

Unless otherwise overridden, socket timeout defaults to -1. This value
is then converted to milliseconds (-1000) and used as argument to the
poll syscall. poll returns EINVAL (22), and the connection fails.

This bug was discovered during the EINTR handling testing, and the
reproduction code can be found in
https://bugs.python.org/issue23618 (see connect_eintr.py,
attached). On GNU/Linux, the example runs as expected.

This change is trivial:
If the supplied timeout value is negative, truncate it to -1.
(cherry picked from commit 28146206578ebe1b84b48e6f255738a227058c04)

Co-authored-by: Artem Khramov &lt;akhramov@pm.me&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>[3.7] bpo-36254: Fix invalid uses of %d in format strings in C. (GH-12264). (GH-12322)</title>
<updated>2019-03-14T08:47:27+00:00</updated>
<author>
<name>Serhiy Storchaka</name>
<email>storchaka@gmail.com</email>
</author>
<published>2019-03-14T08:47:27+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=783bed4c8daf65a2893d94761ea44af4e3718f4f'/>
<id>783bed4c8daf65a2893d94761ea44af4e3718f4f</id>
<content type='text'>
(cherry picked from commit d53fe5f407ff4b529628b01a1bcbf21a6aad5c3a)

Co-authored-by: Serhiy Storchaka &lt;storchaka@gmail.com&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
(cherry picked from commit d53fe5f407ff4b529628b01a1bcbf21a6aad5c3a)

Co-authored-by: Serhiy Storchaka &lt;storchaka@gmail.com&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>bpo-35550: Fix incorrect Solaris define guards (GH-11275)</title>
<updated>2018-12-31T02:39:00+00:00</updated>
<author>
<name>Miss Islington (bot)</name>
<email>31488909+miss-islington@users.noreply.github.com</email>
</author>
<published>2018-12-31T02:39:00+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=d82344378ad8e471b8ed12fb99807f68351c5412'/>
<id>d82344378ad8e471b8ed12fb99807f68351c5412</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_systemGH-Solaris

https://bugs.python.org/issue35550
(cherry picked from commit 6f9bc72c79c3262e5d0f2c0e96b016477399cfb1)

Co-authored-by: Jakub Kulík &lt;Kulikjak@gmail.com&gt;</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_systemGH-Solaris

https://bugs.python.org/issue35550
(cherry picked from commit 6f9bc72c79c3262e5d0f2c0e96b016477399cfb1)

Co-authored-by: Jakub Kulík &lt;Kulikjak@gmail.com&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>bpo-35214: MSan workarounds for socket, time, and test_faulthandler. (GH-11375) (GH-11378)</title>
<updated>2018-12-31T01:59:19+00:00</updated>
<author>
<name>Miss Islington (bot)</name>
<email>31488909+miss-islington@users.noreply.github.com</email>
</author>
<published>2018-12-31T01:59:19+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=01b9664740307b39c2907bd84cbb0b2c35be9df4'/>
<id>01b9664740307b39c2907bd84cbb0b2c35be9df4</id>
<content type='text'>
Add Clang Memory Sanitizer build instrumentation to work around
false positives from the socket and time modules as well as skipping
a couple test_faulthandler tests.
(cherry picked from commit b474e6774d60fa67d5373e361a0ed53c18b24f53)

Co-authored-by: Gregory P. Smith &lt;greg@krypto.org&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Add Clang Memory Sanitizer build instrumentation to work around
false positives from the socket and time modules as well as skipping
a couple test_faulthandler tests.
(cherry picked from commit b474e6774d60fa67d5373e361a0ed53c18b24f53)

Co-authored-by: Gregory P. Smith &lt;greg@krypto.org&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>bpo-35454: Fix miscellaneous minor issues in error handling. (GH-11077)</title>
<updated>2018-12-11T07:05:13+00:00</updated>
<author>
<name>Miss Islington (bot)</name>
<email>31488909+miss-islington@users.noreply.github.com</email>
</author>
<published>2018-12-11T07:05:13+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=62674f3a36ec55f86a5f20ee028a37fbd549bd6c'/>
<id>62674f3a36ec55f86a5f20ee028a37fbd549bd6c</id>
<content type='text'>
* bpo-35454: Fix miscellaneous minor issues in error handling.

* Fix a null pointer dereference.
(cherry picked from commit 8905fcc85a6fc3ac394bc89b0bbf40897e9497a6)

Co-authored-by: Serhiy Storchaka &lt;storchaka@gmail.com&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* bpo-35454: Fix miscellaneous minor issues in error handling.

* Fix a null pointer dereference.
(cherry picked from commit 8905fcc85a6fc3ac394bc89b0bbf40897e9497a6)

Co-authored-by: Serhiy Storchaka &lt;storchaka@gmail.com&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>bpo-35050: AF_ALG length check off-by-one error (GH-10058) (GH-11069)</title>
<updated>2018-12-10T11:13:01+00:00</updated>
<author>
<name>Victor Stinner</name>
<email>vstinner@redhat.com</email>
</author>
<published>2018-12-10T11:13:01+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=1a7b62d5571b3742e706d247dfe6509f68f1409d'/>
<id>1a7b62d5571b3742e706d247dfe6509f68f1409d</id>
<content type='text'>
The length check for AF_ALG salg_name and salg_type had a off-by-one
error. The code assumed that both values are not necessarily NULL
terminated. However the Kernel code for alg_bind() ensures that the last
byte of both strings are NULL terminated.

Signed-off-by: Christian Heimes &lt;christian@python.org&gt;
(cherry picked from commit 2eb6ad8578fa9d764c21a92acd8e054e3202ad19)</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The length check for AF_ALG salg_name and salg_type had a off-by-one
error. The code assumed that both values are not necessarily NULL
terminated. However the Kernel code for alg_bind() ensures that the last
byte of both strings are NULL terminated.

Signed-off-by: Christian Heimes &lt;christian@python.org&gt;
(cherry picked from commit 2eb6ad8578fa9d764c21a92acd8e054e3202ad19)</pre>
</div>
</content>
</entry>
<entry>
<title>Fix a possible reference leak in _socket.getaddrinfo(). (GH-10543)</title>
<updated>2018-11-15T09:25:34+00:00</updated>
<author>
<name>Miss Islington (bot)</name>
<email>31488909+miss-islington@users.noreply.github.com</email>
</author>
<published>2018-11-15T09:25:34+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=b5ea5e57f5dd23e1db695dda8bf3f6142ed9074f'/>
<id>b5ea5e57f5dd23e1db695dda8bf3f6142ed9074f</id>
<content type='text'>
"single" needs to be decrefed if PyList_Append() fails.
(cherry picked from commit 4c596d54aa6a55e9d2a3db78891e656ebbfb63c8)

Co-authored-by: Zackery Spytz &lt;zspytz@gmail.com&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
"single" needs to be decrefed if PyList_Append() fails.
(cherry picked from commit 4c596d54aa6a55e9d2a3db78891e656ebbfb63c8)

Co-authored-by: Zackery Spytz &lt;zspytz@gmail.com&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>[3.7] closes bpo-25041: Document AF_PACKET socket address format. (GH-9207)</title>
<updated>2018-09-12T01:46:36+00:00</updated>
<author>
<name>Benjamin Peterson</name>
<email>benjamin@python.org</email>
</author>
<published>2018-09-12T01:46:36+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=cadb66e173ded86ebc85b54889db48f66e7af592'/>
<id>cadb66e173ded86ebc85b54889db48f66e7af592</id>
<content type='text'>
(cherry picked from commit 731ff68eeef58babdf2b32dc9a73b141760c2be9)

Co-authored-by: Cheryl Sabella &lt;cheryl.sabella@gmail.com&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
(cherry picked from commit 731ff68eeef58babdf2b32dc9a73b141760c2be9)

Co-authored-by: Cheryl Sabella &lt;cheryl.sabella@gmail.com&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>closes bpo-34581 : Conditionalize use of __pragma in Modules/socketmodule.c. (GH-9067)</title>
<updated>2018-09-05T06:45:03+00:00</updated>
<author>
<name>Miss Islington (bot)</name>
<email>31488909+miss-islington@users.noreply.github.com</email>
</author>
<published>2018-09-05T06:45:03+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=5b17d7fccd8f0b4d5030b03924eb00904585ba31'/>
<id>5b17d7fccd8f0b4d5030b03924eb00904585ba31</id>
<content type='text'>
(cherry picked from commit 874809ea389e6434787e773a6054a08e0b81f734)

Co-authored-by: Erik Janssens &lt;erik.janssens@conceptive.be&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
(cherry picked from commit 874809ea389e6434787e773a6054a08e0b81f734)

Co-authored-by: Erik Janssens &lt;erik.janssens@conceptive.be&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>bpo-34217: Use lowercase for windows headers (GH-8472)</title>
<updated>2018-08-16T07:29:20+00:00</updated>
<author>
<name>Miss Islington (bot)</name>
<email>31488909+miss-islington@users.noreply.github.com</email>
</author>
<published>2018-08-16T07:29:20+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=bf8e9d18dd75f58ce3b9761763ae10c0800b43d8'/>
<id>bf8e9d18dd75f58ce3b9761763ae10c0800b43d8</id>
<content type='text'>
(cherry picked from commit e6a4755e6793942b950c1595e0c34bd66a0ee13e)

Co-authored-by: Erik Janssens &lt;erik.janssens@conceptive.be&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
(cherry picked from commit e6a4755e6793942b950c1595e0c34bd66a0ee13e)

Co-authored-by: Erik Janssens &lt;erik.janssens@conceptive.be&gt;</pre>
</div>
</content>
</entry>
</feed>
