aboutsummaryrefslogtreecommitdiffstats
path: root/erts/emulator/beam
diff options
context:
space:
mode:
Diffstat (limited to 'erts/emulator/beam')
-rw-r--r--erts/emulator/beam/erl_init.c16
-rw-r--r--erts/emulator/beam/sys.h2
2 files changed, 3 insertions, 15 deletions
diff --git a/erts/emulator/beam/erl_init.c b/erts/emulator/beam/erl_init.c
index 41cfcd74aa..5a7e0649c9 100644
--- a/erts/emulator/beam/erl_init.c
+++ b/erts/emulator/beam/erl_init.c
@@ -1453,13 +1453,7 @@ __decl_noreturn void erl_exit0(char *file, int line, int n, char *fmt,...)
if (fmt != NULL && *fmt != '\0')
erl_error(fmt, args); /* Print error message. */
va_end(args);
-#ifdef __WIN32__
- if(n > 0) ConWaitForExit();
- else ConNormalExit();
-#endif
-#if !defined(__WIN32__) && !defined(VXWORKS) && !defined(_OSE_)
- sys_tty_reset();
-#endif
+ sys_tty_reset(n);
if (n == ERTS_INTR_EXIT)
exit(0);
@@ -1499,13 +1493,7 @@ __decl_noreturn void erl_exit(int n, char *fmt,...)
if (fmt != NULL && *fmt != '\0')
erl_error(fmt, args); /* Print error message. */
va_end(args);
-#ifdef __WIN32__
- if(n > 0) ConWaitForExit();
- else ConNormalExit();
-#endif
-#if !defined(__WIN32__) && !defined(VXWORKS) && !defined(_OSE_)
- sys_tty_reset();
-#endif
+ sys_tty_reset(n);
if (n == ERTS_INTR_EXIT)
exit(0);
diff --git a/erts/emulator/beam/sys.h b/erts/emulator/beam/sys.h
index a86bcb80dd..1998a2bc9f 100644
--- a/erts/emulator/beam/sys.h
+++ b/erts/emulator/beam/sys.h
@@ -686,7 +686,7 @@ extern void erl_sys_schedule(int);
#ifdef _OSE_
extern void erl_sys_init_final(void);
#else
-void sys_tty_reset(void);
+void sys_tty_reset(int);
#endif
EXTERN_FUNCTION(int, sys_max_files, (_VOID_));