summaryrefslogtreecommitdiffstats
path: root/Modules/collectionsmodule.c
diff options
context:
space:
mode:
Diffstat (limited to 'Modules/collectionsmodule.c')
-rw-r--r--Modules/collectionsmodule.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Modules/collectionsmodule.c b/Modules/collectionsmodule.c
index d761dce..cb12b3a 100644
--- a/Modules/collectionsmodule.c
+++ b/Modules/collectionsmodule.c
@@ -211,6 +211,7 @@ deque_popleft(dequeobject *deque, PyObject *unused)
PyErr_SetString(PyExc_IndexError, "pop from an empty deque");
return NULL;
}
+ assert(deque->leftblock != NULL);
item = deque->leftblock->data[deque->leftindex];
deque->leftindex++;
deque->len--;
@@ -226,7 +227,6 @@ deque_popleft(dequeobject *deque, PyObject *unused)
} else {
assert(deque->leftblock != deque->rightblock);
prevblock = deque->leftblock->rightlink;
- assert(deque->leftblock != NULL);
PyMem_Free(deque->leftblock);
assert(prevblock != NULL);
prevblock->leftlink = NULL;