butc: Catch failures to start keep alive thread
[openafs.git] / src / butc / tcudbprocs.c
index 386360a..322c617 100644 (file)
@@ -490,10 +490,14 @@ writeDbDump(struct butm_tapeInfo *tapeInfoPtr, afs_uint32 taskId,
                AFS_SIGSET_RESTORE();
 #else
                code =
-                   LWP_CreateProcess(KeepAlive, 16384, 1, (void *)NULL,
+                   LWP_CreateProcess(KeepAlive, 16384, 1, NULL,
                                      "Keep-alive process", &alivePid);
 #endif
-               /* XXX should we check code here ??? XXX */
+               if (code) {
+                   ErrorLog(0, taskId, code, 0,
+                            "Failed to create keep alive process\n");
+                   ERROR_EXIT(code);
+               }
            }
            firstcall = 0;