diff --git a/knots/resource-pool.scm b/knots/resource-pool.scm index 17919a6..ac536cc 100644 --- a/knots/resource-pool.scm +++ b/knots/resource-pool.scm @@ -341,7 +341,14 @@ start (cdr end)))) - (loop (remove-at-index! resources index) + (loop (if index + (remove-at-index! resources index) + (begin + (simple-format + (current-error-port) + "resource pool error: unable to remove ~A\n" + resource) + resources)) available ; resource shouldn't be in this list waiters (remove-at-index!