summaryrefslogtreecommitdiffstats
path: root/winsup/cygwin/dcrt0.cc
diff options
context:
space:
mode:
Diffstat (limited to 'winsup/cygwin/dcrt0.cc')
-rw-r--r--winsup/cygwin/dcrt0.cc1
1 files changed, 1 insertions, 0 deletions
diff --git a/winsup/cygwin/dcrt0.cc b/winsup/cygwin/dcrt0.cc
index 6a1a341aa..76b89517b 100644
--- a/winsup/cygwin/dcrt0.cc
+++ b/winsup/cygwin/dcrt0.cc
@@ -1127,6 +1127,7 @@ cygwin_atexit (void (*fn) (void))
extern "C" void
cygwin_exit (int n)
{
+ exit_state = ES_EXIT_STARTING;
exit (n);
}