Index: /trunk/src/kWorker/kWorker.c
===================================================================
--- /trunk/src/kWorker/kWorker.c	(revision 3199)
+++ /trunk/src/kWorker/kWorker.c	(revision 3200)
@@ -9534,22 +9534,4 @@
 KU32 const                  g_cSandboxGetProcReplacements = K_ELEMENTS(g_aSandboxGetProcReplacements);
 
-/**
- * Thread that is spawned by the first terminal kwSandboxCtrlHandler invocation.
- *
- * This will wait 5 second in a hope that the main thread will shut down the
- * process nicly, otherwise it will terminate it forcefully.
- */
-static DWORD WINAPI kwSandboxCtrlThreadProc(PVOID pvUser)
-{
-    int i;
-    for (i = 0; i < 10; i++)
-    {
-        Sleep(500);
-        CancelIoEx(g_hPipe, NULL);
-    }
-    TerminateProcess(GetCurrentProcess(), (int)(intptr_t)pvUser);
-    return -1;
-}
-
 
 /**
@@ -9599,10 +9581,4 @@
     /*
      * Terminate the process after 5 seconds.
-     *
-     * We don't want to wait here as the console server will otherwise not
-     * signal the other processes in the console, which is bad for kmk as it
-     * will continue to forge ahead.  So, the first time we get here we start
-     * a thread for doing the delayed termination.
-     *
      * If we get here a second time we just terminate the process ourselves.
      *
@@ -9613,9 +9589,12 @@
     g_rcCtrlC = rc;
     WriteFile(GetStdHandle(STD_ERROR_HANDLE), pszMsg, (DWORD)strlen(pszMsg), &cbIgn, NULL);
-    CancelIoEx(g_hPipe, NULL); /* wake up idle main thread */
     if (rcPrev == 0)
     {
-        CreateThread(NULL, 0, kwSandboxCtrlThreadProc, (void*)(intptr_t)rc, 0 /*fFlags*/, NULL);
-        return TRUE;
+        int i;
+        for (i = 0; i < 10; i++)
+        {
+            CancelIoEx(g_hPipe, NULL); /* wake up idle main thread */
+            Sleep(500);
+        }
     }
     TerminateProcess(GetCurrentProcess(), rc);
Index: /trunk/src/kmk/kmkbuiltin/kSubmit.c
===================================================================
--- /trunk/src/kmk/kmkbuiltin/kSubmit.c	(revision 3199)
+++ /trunk/src/kmk/kmkbuiltin/kSubmit.c	(revision 3200)
@@ -71,4 +71,5 @@
 
 #define TUPLE(a_sz)     a_sz, sizeof(a_sz) - 1
+
 
 /*********************************************************************************************************************************
@@ -1151,5 +1152,5 @@
 # else
         if (MkWinChildCreateSubmit((intptr_t)pWorker->OverlappedRead.hEvent, pWorker,
-                                   pWorker->pStdOut, pWorker->pStdErr, pPidSpawned) == 0)
+                                   pWorker->pStdOut, pWorker->pStdErr, pChild, pPidSpawned) == 0)
         { /* likely */ }
         else
@@ -1691,7 +1692,10 @@
                the kWorker process currently does not coordinate its output with
                the output.c mechanics. */
+#ifdef CONFIG_NEW_WIN_CHILDREN
+            if (pCtx->pOut && !pWorker->pStdOut)
+#else
             if (pCtx->pOut)
+#endif
                 output_dump(pCtx->pOut);
-
             rcExit = kSubmitSendJobMessage(pCtx, pWorker, pvMsg, cbMsg, 0 /*fNoRespawning*/, cVerbosity);
             if (rcExit == 0)
Index: /trunk/src/kmk/output.c
===================================================================
--- /trunk/src/kmk/output.c	(revision 3199)
+++ /trunk/src/kmk/output.c	(revision 3200)
@@ -131,12 +131,12 @@
               const char *nl = (const char *)memchr (src, '\n', len);
               size_t line_len = nl ? nl - (const char *)src + 1 : len;
-              char *tmp = (char *)xmalloc (2 + line_len + 1);
-              tmp[0] = '>';
-              tmp[1] = ' ';
-              memcpy (&tmp[2], src, line_len);
+              char *tmp = (char *)xmalloc (1 + line_len + 1 + 1);
+              tmp[0] = '{';
+              memcpy (&tmp[1], src, line_len);
+              tmp[1 + line_len] = '}';
 #  ifdef KBUILD_OS_WINDOWS
-              maybe_con_fwrite (tmp, 2 + line_len, 1, dst);
+              maybe_con_fwrite (tmp, 1 + line_len + 1, 1, dst);
 #  else
-              fwrite (tmp, 2 + line_len, 1, dst);
+              fwrite (tmp, 1 + line_len + 1, 1, dst);
 #  endif
               free (tmp);
Index: /trunk/src/kmk/w32/winchildren.c
===================================================================
--- /trunk/src/kmk/w32/winchildren.c	(revision 3199)
+++ /trunk/src/kmk/w32/winchildren.c	(revision 3200)
@@ -3118,11 +3118,14 @@
  * @param   hEvent          The event object handle to wait on.
  * @param   pvSubmitWorker  The argument to pass back to kSubmit to clean up.
- * @param   pPid            Where to return the pid.
  * @param   pStdOut         Standard output pipe for the worker. Optional.
  * @param   pStdErr         Standard error pipe for the worker. Optional.
- */
-int MkWinChildCreateSubmit(intptr_t hEvent, void *pvSubmitWorker, PWINCCWPIPE pStdOut, PWINCCWPIPE pStdErr, pid_t *pPid)
+ * @param   pMkChild        The make child structure.
+ * @param   pPid            Where to return the pid.
+ */
+int MkWinChildCreateSubmit(intptr_t hEvent, void *pvSubmitWorker, PWINCCWPIPE pStdOut, PWINCCWPIPE pStdErr,
+                           struct child *pMkChild, pid_t *pPid)
 {
     PWINCHILD pChild = mkWinChildNew(WINCHILDTYPE_SUBMIT);
+    pChild->pMkChild                = pMkChild;
     pChild->u.Submit.hEvent         = (HANDLE)hEvent;
     pChild->u.Submit.pvSubmitWorker = pvSubmitWorker;
Index: /trunk/src/kmk/w32/winchildren.h
===================================================================
--- /trunk/src/kmk/w32/winchildren.h	(revision 3199)
+++ /trunk/src/kmk/w32/winchildren.h	(revision 3200)
@@ -75,5 +75,6 @@
                                struct child *pMkChild, pid_t *pPid);
 
-int     MkWinChildCreateSubmit(intptr_t hEvent, void *pvSubmitWorker, PWINCCWPIPE pStdOut, PWINCCWPIPE pStdErr, pid_t *pPid);
+int     MkWinChildCreateSubmit(intptr_t hEvent, void *pvSubmitWorker, PWINCCWPIPE pStdOut, PWINCCWPIPE pStdErr,
+                               struct child *pMkChild, pid_t *pPid);
 PWINCCWPIPE MkWinChildcareCreateWorkerPipe(unsigned iWhich, unsigned int idxWorker);
 void    MkWinChildcareWorkerDrainPipes(struct WINCHILD *pChild, PWINCCWPIPE pStdOut, PWINCCWPIPE pStdErr);
