summaryrefslogtreecommitdiff
path: root/python2.7/patches/issue15340.diff
diff options
context:
space:
mode:
authorIgor Pashev <igor.pashev@nexenta.com>2013-04-10 11:42:21 +0400
committerIgor Pashev <igor.pashev@nexenta.com>2013-04-10 11:42:21 +0400
commit3fd7c70391fef9a1593b25a808766c352239e958 (patch)
tree8ed845aca8afc7bf489028a31db0fdf5ad6ce680 /python2.7/patches/issue15340.diff
parent92b26142a3d204fb1ce30f68ba1dfdd7f92a0b36 (diff)
downloadcibs-pkgs-3fd7c70391fef9a1593b25a808766c352239e958.tar.gz
Adapt Debian patches
Diffstat (limited to 'python2.7/patches/issue15340.diff')
-rw-r--r--python2.7/patches/issue15340.diff16
1 files changed, 16 insertions, 0 deletions
diff --git a/python2.7/patches/issue15340.diff b/python2.7/patches/issue15340.diff
new file mode 100644
index 0000000..31cc6ed
--- /dev/null
+++ b/python2.7/patches/issue15340.diff
@@ -0,0 +1,16 @@
+# DP: - Issue #15340: Fix importing the random module when /dev/urandom cannot
+# DP: be opened. This was a regression caused by the hash randomization patch.
+
+diff -r 8cd6acffbcb9 -r edbf37ace03c Python/random.c
+--- a/Python/random.c Fri Sep 07 00:55:33 2012 +0200
++++ b/Python/random.c Fri Sep 07 23:49:07 2012 +0200
+@@ -165,7 +165,8 @@
+ Py_END_ALLOW_THREADS
+ if (fd < 0)
+ {
+- PyErr_SetFromErrnoWithFilename(PyExc_OSError, "/dev/urandom");
++ PyErr_SetString(PyExc_NotImplementedError,
++ "/dev/urandom (or equivalent) not found");
+ return -1;
+ }
+