diff options
author | Benjamin Peterson <benjamin@python.org> | 2012-02-21 16:08:50 (GMT) |
---|---|---|
committer | Benjamin Peterson <benjamin@python.org> | 2012-02-21 16:08:50 (GMT) |
commit | 69e9727657dad167215b656de910d95cefe1ee45 (patch) | |
tree | e90351e4f45e2f07dbd3bb4c877da686075fec1e /Objects/bytesobject.c | |
parent | 9571155ae4ff86b4275950fcdfadcc76475943e3 (diff) | |
download | cpython-69e9727657dad167215b656de910d95cefe1ee45.zip cpython-69e9727657dad167215b656de910d95cefe1ee45.tar.gz cpython-69e9727657dad167215b656de910d95cefe1ee45.tar.bz2 |
ensure no one tries to hash things before the random seed is found
Diffstat (limited to 'Objects/bytesobject.c')
-rw-r--r-- | Objects/bytesobject.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/Objects/bytesobject.c b/Objects/bytesobject.c index e6ab440..db93f37 100644 --- a/Objects/bytesobject.c +++ b/Objects/bytesobject.c @@ -896,6 +896,7 @@ bytes_hash(PyBytesObject *a) register unsigned char *p; register long x; + assert(_Py_HashSecret_Initialized); if (a->ob_shash != -1) return a->ob_shash; len = Py_SIZE(a); |