Skip to content

Commit 977d8ba

Browse files
committed
Abort abruptly on failure on windows
Trying to shutdown cleanly results in wierd failures
1 parent e3d5b8a commit 977d8ba

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

src/rt/rust_kernel.cpp

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -136,6 +136,12 @@ int rust_kernel::start_task_threads()
136136

137137
void
138138
rust_kernel::fail() {
139+
// FIXME: On windows we're getting "Application has requested the
140+
// Runtime to terminate it in an unusual way" when trying to shutdown
141+
// cleanly.
142+
#if defined(__WIN32__)
143+
exit(-1);
144+
#endif
139145
for(size_t i = 0; i < num_threads; ++i) {
140146
rust_scheduler *thread = threads[i];
141147
thread->kill_all_tasks();

0 commit comments

Comments
 (0)