Index: http-transport.scm
==================================================================
--- http-transport.scm
+++ http-transport.scm
@@ -492,11 +492,11 @@
 	      (loop (tasks:server-lock-slot (tasks:get-db) run-id)
 		    (- remtries 1)))
 	    (begin
 	      ;; since we didn't get the server lock we are going to clean up and bail out
 	      (debug:print-info 2 "INFO: server pid=" (current-process-id) ", hostname=" (get-host-name) " not starting due to other candidates ahead in start queue")
-	      (tasks:server-delete-records-for-this-pid tasks:get-db " http-transport:launch")
+	      (tasks:server-delete-records-for-this-pid (tasks:get-db) " http-transport:launch")
 	      ))
 	(let* ((th2 (make-thread (lambda ()
 				   (debug:print-info 0 "Server run thread started")
 				   (http-transport:run 
 				    (if (args:get-arg "-server")

Index: tasks.scm
==================================================================
--- tasks.scm
+++ tasks.scm
@@ -118,11 +118,11 @@
 	  ))
     mdb))
 
 (define (tasks:get-db)
   (if *task-db*
-      *task-db*
+      (vector-ref *task-db* 0)
       (let ((db  (tasks:open-db))
 	    (pth (tasks:get-task-db-path)))
 	(set! *task-db* (vector db pth))
 	db)))