- Patch #602306 by David Strauss, Damien Tournoud: Fixed bug in the default queue implementation.

merge-requests/26/head
Dries Buytaert 2009-10-14 10:59:15 +00:00
parent a019a9ebb0
commit 30fa81a763
1 changed files with 1 additions and 1 deletions

View File

@ -198,7 +198,7 @@ class SystemQueue implements DrupalQueueInterface {
// until an item is successfully claimed or we are reasonably sure there
// are no unclaimed items left.
while (TRUE) {
$item = db_query_range('SELECT data, item_id FROM {queue} q WHERE name = :name ORDER BY created ASC', 0, 1, array(':name' => $this->name))->fetchObject();
$item = db_query_range('SELECT data, item_id FROM {queue} q WHERE expire = 0 AND name = :name ORDER BY created ASC', 0, 1, array(':name' => $this->name))->fetchObject();
if ($item) {
// Try to update the item. Only one thread can succeed in UPDATEing the
// same row. We cannot rely on REQUEST_TIME because items might be