summaryrefslogtreecommitdiffstats
path: root/Objects/unicodeobject.c
diff options
context:
space:
mode:
authorBenjamin Peterson <benjamin@python.org>2012-02-21 16:08:50 (GMT)
committerBenjamin Peterson <benjamin@python.org>2012-02-21 16:08:50 (GMT)
commit26da920001941b0cd74981772924a6aab4d2881a (patch)
tree89683553a0a02950f41b652e225b062736ed1ae7 /Objects/unicodeobject.c
parentb69fa1f8b7b935c79b193502358bd59b685afd77 (diff)
downloadcpython-26da920001941b0cd74981772924a6aab4d2881a.zip
cpython-26da920001941b0cd74981772924a6aab4d2881a.tar.gz
cpython-26da920001941b0cd74981772924a6aab4d2881a.tar.bz2
ensure no one tries to hash things before the random seed is found
Diffstat (limited to 'Objects/unicodeobject.c')
-rw-r--r--Objects/unicodeobject.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/Objects/unicodeobject.c b/Objects/unicodeobject.c
index 2f80e59..1df38e8 100644
--- a/Objects/unicodeobject.c
+++ b/Objects/unicodeobject.c
@@ -6692,6 +6692,7 @@ unicode_hash(PyUnicodeObject *self)
register Py_UNICODE *p;
register long x;
+ assert(_Py_HashSecret_Initialized);
if (self->hash != -1)
return self->hash;
len = PyUnicode_GET_SIZE(self);