]> granicus.if.org Git - python/commitdiff
Fix _sha3 module to actually release the GIL around its update function.
authorChristian Heimes <christian@cheimes.de>
Wed, 31 Jul 2013 09:58:18 +0000 (11:58 +0200)
committerChristian Heimes <christian@cheimes.de>
Wed, 31 Jul 2013 09:58:18 +0000 (11:58 +0200)
gcov is great.

Modules/_sha3/sha3module.c

index 32cd85a1efa9d898b27a508a44d58790db70843c..0f47fc342934561ed75dc11f3c1b231cc7fc248b 100644 (file)
@@ -322,7 +322,7 @@ SHA3_update(SHA3object *self, PyObject *args)
     GET_BUFFER_VIEW_OR_ERROUT(obj, &buf);
 
     /* add new data, the function takes the length in bits not bytes */
-#ifdef WITH_THREADS
+#ifdef WITH_THREAD
     if (self->lock == NULL && buf.len >= HASHLIB_GIL_MINSIZE) {
         self->lock = PyThread_allocate_lock();
     }