From 12ab2f4b851a9fd47f34bc38328a0fb5492a6098 Mon Sep 17 00:00:00 2001 From: Cory McWilliams Date: Tue, 28 Dec 2021 19:47:32 +0000 Subject: [PATCH] Don't let promise IDs be zero. git-svn-id: https://www.unprompted.com/svn/projects/tildefriends/trunk@3713 ed5197a5-7fde-0310-b194-c3ffbd925b24 --- src/task.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/task.c b/src/task.c index 47f44456..977e66f9 100644 --- a/src/task.c +++ b/src/task.c @@ -1068,7 +1068,7 @@ promiseid_t tf_task_allocate_promise(tf_task_t* task) promiseid_t promiseId; do { promiseId = task->_nextPromise++; - } while (_tf_task_find_promise(task, promiseId)); + } while (_tf_task_find_promise(task, promiseId) || !promiseId); promise_t promise = {