diff options
Diffstat (limited to 'winsup/cygwin/exceptions.cc')
-rw-r--r-- | winsup/cygwin/exceptions.cc | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/winsup/cygwin/exceptions.cc b/winsup/cygwin/exceptions.cc index 41a1319..a948116 100644 --- a/winsup/cygwin/exceptions.cc +++ b/winsup/cygwin/exceptions.cc @@ -383,19 +383,19 @@ try_to_debug (bool waitloop) &si, &pi); - static int NO_COPY keep_looping = 0; - - if (dbg) + if (!dbg) + system_printf ("Failed to start debugger: %E"); + else { if (!waitloop) return 1; SetThreadPriority (hMainThread, THREAD_PRIORITY_IDLE); - while (keep_looping) + while (!IsDebuggerPresent ()) /* spin */; + Sleep (4000); + small_printf ("*** continuing from debugger call\n"); } - - system_printf ("Failed to start debugger: %E"); /* FIXME: need to know handles of all running threads to resume_all_threads_except (current_thread_id); */ |