<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/cpython-git.git/Modules/socketmodule.c, branch v3.8.3</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-40121: Fixes audit event raised on creating a new socket (GH-19238)</title>
<updated>2020-03-31T11:57:06+00:00</updated>
<author>
<name>Miss Islington (bot)</name>
<email>31488909+miss-islington@users.noreply.github.com</email>
</author>
<published>2020-03-31T11:57:06+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=6a0ee60db4cee4a01bae1a2922d21a859e9ea2ed'/>
<id>6a0ee60db4cee4a01bae1a2922d21a859e9ea2ed</id>
<content type='text'>
(cherry picked from commit 63ba5cccf484b9ec23dfbf4cf7ffdc833eda98c3)

Co-authored-by: Steve Dower &lt;steve.dower@python.org&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
(cherry picked from commit 63ba5cccf484b9ec23dfbf4cf7ffdc833eda98c3)

Co-authored-by: Steve Dower &lt;steve.dower@python.org&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>closes bpo-37405: Make socket.getsockname() always return a tuple for AF_CAN. (GH-14392) (GH-16018)</title>
<updated>2019-09-12T10:34:28+00:00</updated>
<author>
<name>Miss Islington (bot)</name>
<email>31488909+miss-islington@users.noreply.github.com</email>
</author>
<published>2019-09-12T10:34:28+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=f60fd95dcc189ace8c0a2177a394b9cc20389a1e'/>
<id>f60fd95dcc189ace8c0a2177a394b9cc20389a1e</id>
<content type='text'>
This fixes a regression from 3.5. In recent releases, `getsockname()` in the AF_CAN case has returned a string.
(cherry picked from commit 954900a3f98a8c0dea14dd575490237f3f8626b3)

Co-authored-by: bggardner &lt;brent@ebrent.net&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This fixes a regression from 3.5. In recent releases, `getsockname()` in the AF_CAN case has returned a string.
(cherry picked from commit 954900a3f98a8c0dea14dd575490237f3f8626b3)

Co-authored-by: bggardner &lt;brent@ebrent.net&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>bpo-37811: FreeBSD, OSX: fix poll(2) usage in sockets module (GH-15202)</title>
<updated>2019-08-14T21:47:43+00:00</updated>
<author>
<name>Miss Islington (bot)</name>
<email>31488909+miss-islington@users.noreply.github.com</email>
</author>
<published>2019-08-14T21:47:43+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=123f6c4914827c4ced65d032fab74de62db31cd6'/>
<id>123f6c4914827c4ced65d032fab74de62db31cd6</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>bpo-37085: Expose SocketCAN bcm_msg_head flags (GH-13646)</title>
<updated>2019-07-31T09:10:38+00:00</updated>
<author>
<name>Miss Islington (bot)</name>
<email>31488909+miss-islington@users.noreply.github.com</email>
</author>
<published>2019-07-31T09:10:38+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=d8b914a30b0849476345a19ce0a0ab1ade171b19'/>
<id>d8b914a30b0849476345a19ce0a0ab1ade171b19</id>
<content type='text'>
Expose the CAN_BCM SocketCAN constants used in the bcm_msg_head struct
flags (provided by &lt;linux/can/bcm.h&gt;) under the socket library.

This adds the following constants with a CAN_BCM prefix:

  * SETTIMER
  * STARTTIMER
  * TX_COUNTEVT
  * TX_ANNOUNCE
  * TX_CP_CAN_ID
  * RX_FILTER_ID
  * RX_CHECK_DLC
  * RX_NO_AUTOTIMER
  * RX_ANNOUNCE_RESUME
  * TX_RESET_MULTI_IDX
  * RX_RTR_FRAME
  * CAN_FD_FRAME

The CAN_FD_FRAME flag was introduced in the 4.8 kernel, while the other
ones were present since SocketCAN drivers were mainlined in 2.6.25. As
such, it is probably unnecessary to guard against these constants being
missing.
(cherry picked from commit 31c4fd2a10d90beaa37d630e5f74a471e14e089d)

Co-authored-by: karl ding &lt;karlding@users.noreply.github.com&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Expose the CAN_BCM SocketCAN constants used in the bcm_msg_head struct
flags (provided by &lt;linux/can/bcm.h&gt;) under the socket library.

This adds the following constants with a CAN_BCM prefix:

  * SETTIMER
  * STARTTIMER
  * TX_COUNTEVT
  * TX_ANNOUNCE
  * TX_CP_CAN_ID
  * RX_FILTER_ID
  * RX_CHECK_DLC
  * RX_NO_AUTOTIMER
  * RX_ANNOUNCE_RESUME
  * TX_RESET_MULTI_IDX
  * RX_RTR_FRAME
  * CAN_FD_FRAME

The CAN_FD_FRAME flag was introduced in the 4.8 kernel, while the other
ones were present since SocketCAN drivers were mainlined in 2.6.25. As
such, it is probably unnecessary to guard against these constants being
missing.
(cherry picked from commit 31c4fd2a10d90beaa37d630e5f74a471e14e089d)

Co-authored-by: karl ding &lt;karlding@users.noreply.github.com&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>bpo-36974: tp_print -&gt; tp_vectorcall_offset and tp_reserved -&gt; tp_as_async (GH-13464)</title>
<updated>2019-05-31T02:13:39+00:00</updated>
<author>
<name>Jeroen Demeyer</name>
<email>J.Demeyer@UGent.be</email>
</author>
<published>2019-05-31T02:13:39+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=530f506ac91338b55cf2be71b1cdf50cb077512f'/>
<id>530f506ac91338b55cf2be71b1cdf50cb077512f</id>
<content type='text'>
Automatically replace
tp_print -&gt; tp_vectorcall_offset
tp_compare -&gt; tp_as_async
tp_reserved -&gt; tp_as_async
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Automatically replace
tp_print -&gt; tp_vectorcall_offset
tp_compare -&gt; tp_as_async
tp_reserved -&gt; tp_as_async
</pre>
</div>
</content>
</entry>
<entry>
<title>bpo-37007: Implement socket.if_nametoindex(), if_indextoname() and if_nameindex() on Windows (GH-13522)</title>
<updated>2019-05-29T21:02:37+00:00</updated>
<author>
<name>Zackery Spytz</name>
<email>zspytz@gmail.com</email>
</author>
<published>2019-05-29T21:02:37+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=8f96c9f8ed2a4795e34b333411451e24f28f74d2'/>
<id>8f96c9f8ed2a4795e34b333411451e24f28f74d2</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>bpo-32388: Remove cross-version binary compatibility requirement in tp_flags (GH-4944)</title>
<updated>2019-05-29T20:12:38+00:00</updated>
<author>
<name>Antoine Pitrou</name>
<email>antoine@python.org</email>
</author>
<published>2019-05-29T20:12:38+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=ada319bb6d0ebcc68d3e0ef2b4279ea061877ac8'/>
<id>ada319bb6d0ebcc68d3e0ef2b4279ea061877ac8</id>
<content type='text'>
It is now allowed to add new fields at the end of the PyTypeObject struct without having to allocate a dedicated compatibility flag in tp_flags.

This will reduce the risk of running out of bits in the 32-bit tp_flags value.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
It is now allowed to add new fields at the end of the PyTypeObject struct without having to allocate a dedicated compatibility flag in tp_flags.

This will reduce the risk of running out of bits in the 32-bit tp_flags value.
</pre>
</div>
</content>
</entry>
<entry>
<title>bpo-36842: Implement PEP 578 (GH-12613)</title>
<updated>2019-05-23T15:45:22+00:00</updated>
<author>
<name>Steve Dower</name>
<email>steve.dower@microsoft.com</email>
</author>
<published>2019-05-23T15:45:22+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=b82e17e626f7b1cd98aada0b1ebb65cb9f8fb184'/>
<id>b82e17e626f7b1cd98aada0b1ebb65cb9f8fb184</id>
<content type='text'>
Adds sys.audit, sys.addaudithook, io.open_code, and associated C APIs.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Adds sys.audit, sys.addaudithook, io.open_code, and associated C APIs.</pre>
</div>
</content>
</entry>
<entry>
<title>bpo-29515: add missing socket.IPPROTO_* constants on Windows (GH-12183)</title>
<updated>2019-03-28T14:20:30+00:00</updated>
<author>
<name>Giampaolo Rodola</name>
<email>g.rodola@gmail.com</email>
</author>
<published>2019-03-28T14:20:30+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=3eca28c61363a03b81b9fb12775490d6e42d8ecf'/>
<id>3eca28c61363a03b81b9fb12775490d6e42d8ecf</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>bpo-8677: use PY_SSIZE_T_CLEAN in socketmodule.c (GH-12467)</title>
<updated>2019-03-20T10:02:46+00:00</updated>
<author>
<name>Inada Naoki</name>
<email>songofacandy@gmail.com</email>
</author>
<published>2019-03-20T10:02:46+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=e9a1dcb4237cb2be71ab05883d472038ea9caf62'/>
<id>e9a1dcb4237cb2be71ab05883d472038ea9caf62</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
</feed>
