]> granicus.if.org Git - python/commit
bpo-1621: Avoid signed integer overflow in set_table_resize(). (GH-9059)
authorSergey Fedoseev <fedoseev.sergey@gmail.com>
Tue, 11 Sep 2018 23:18:01 +0000 (04:18 +0500)
committerMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Tue, 11 Sep 2018 23:18:01 +0000 (16:18 -0700)
commit6c7d67ce83a62b5f0fe5c53a6df602827451bf7f
tree124db646c91085418871cb49a645c96c700503d9
parent4859ba0d2ce4506fddc3f55f90f8dce031b3804f
bpo-1621: Avoid signed integer overflow in set_table_resize(). (GH-9059)

Address a C undefined behavior signed integer overflow issue in set object table resizing.  Our -fwrapv compiler flag and practical reasons why sets are unlikely to get this large should mean this was never an issue but it was incorrect code that generates code analysis warnings.

<!-- issue-number: [bpo-1621](https://www.bugs.python.org/issue1621) -->
https://bugs.python.org/issue1621
<!-- /issue-number -->
Misc/NEWS.d/next/Core and Builtins/2018-09-11-15-19-37.bpo-1621.7o19yG.rst [new file with mode: 0644]
Objects/setobject.c