Multithreading panics on Windows with MSVC compiler
iopq opened this issue · comments
After running for a while, I get this:
thread '<unnamed>' panicked at 'called `Option::unwrap()` on a `None` value', ..
/src/libcore\option.rs:366
thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: "Se
ndError(..)"', ../src/libcore\result.rs:737
thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: Rec
vError', ../src/libcore\result.rs:737
thread '<unnamed>' panicked at 'called `Option::unwrap()` on a `None` value', ..
/src/libcore\option.rs:366
stack backtrace:
0: 0x7ff6cd9ac18c - sys_common::unwind::imp::rust_eh_personality_catch::h
18a82beac5f589a0wws
1: 0x7ff6cd9a33c8 - sys_common::unwind::imp::rust_eh_personality_catch::h
18a82beac5f589a0wws
2: 0x7ff6cd99cc20 - rust_eh_unwind_resume
3: 0x7ff6cd99d571 - rust_eh_unwind_resume
4: 0x7ff6cd9b5c65 - sys_common::unwind::imp::rust_eh_personality_catch::h
18a82beac5f589a0wws
5: 0x7ff6cd9b18e0 - sys_common::unwind::imp::rust_eh_personality_catch::h
18a82beac5f589a0wws
6: 0x7ff6cd90e7e0 - __ImageBase
7: 0x7ff6cd92a137 - __ImageBase
8: 0x7ff6cd90e04e - __ImageBase
9: 0x7ff6cd9a00ed - rust_eh_unwind_resume
10: 0x7ff6cd90e1b7 - __ImageBase
11: 0x7ff6cd9a5bbd - sys_common::unwind::imp::rust_eh_personality_catch::h
18a82beac5f589a0wws
12: 0x7ffe95a113d1 - BaseThreadInitThunk
thread panicked while panicking. aborting.
maybe we shouldn't unwrap
the thread things because it first panics on send and then panics on receive killing the whole program (not just one thread)
Unfortunately it's hard to tell where exactly this is coming from. In pull request #195 I'm already replacing a few unwrap()
calls with match
expressions and debug output. I guess we need to do that everywhere.
Also crashes with the GNU ABI
Do you get more info now that I've added a few more checks? If not then it's still failing somewhere where we still call unwrap()
and assume that everything just works.
no, it's not giving me any error before crashing
Thanks, I'll have a look at it again then.
Is this still happening?
I'll have to test it on the MSVC compiler again
That would be great. I'd really like to get to the bottom of this. Or maybe we're lucky and due to all the recent changes this doesn't even happen anymore.
I haven't had issues, so closing for now