merge 3.6 (#29085)
diff --git a/Misc/NEWS b/Misc/NEWS
index 1987e75..31fdde1 100644
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -734,6 +734,9 @@
Library
-------
+- Issue #29085: Allow random.Random.seed() to use high quality OS randomness
+ rather than the pid and time.
+
- Issue 28923: Remove editor artifacts from Tix.py.
- Issue #29055: Neaten-up empty population error on random.choice()
diff --git a/Modules/_randommodule.c b/Modules/_randommodule.c
index 63759d5..0d3282d 100644
--- a/Modules/_randommodule.c
+++ b/Modules/_randommodule.c
@@ -245,7 +245,7 @@
return NULL;
if (arg == NULL || arg == Py_None) {
- if (random_seed_urandom(self) >= 0) {
+ if (random_seed_urandom(self) < 0) {
PyErr_Clear();
/* Reading system entropy failed, fall back on the worst entropy: