Commit 8427dec2 authored by Serhiy Storchaka's avatar Serhiy Storchaka

Issue #23115: Fixed compilation on OpenBSD (Py_MIN is not defined in 2.7).

parent ce8d5794
......@@ -102,7 +102,7 @@ static int
py_getentropy(unsigned char *buffer, Py_ssize_t size, int fatal)
{
while (size > 0) {
Py_ssize_t len = Py_MIN(size, 256);
Py_ssize_t len = size < 256 ? size : 256;
int res = getentropy(buffer, len);
if (res < 0) {
if (fatal) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment