This repository was archived by the owner on Oct 12, 2022. It is now read-only.
Commit 1e75c50
committed
Make thread_attachThis nothrow
In case any of the GC operations in the thread_attachThis fail with
the Error, it's likely that GC.enable will also throw an error. This is
not allowed for the statically allocated errors (such as
InvalidMemoryOperationError, commonly thrown by GC), and it will
cause deadlock where the t->next will be same as t.
In order to prevent this, we need to make scope(exit) GC.enable()
scope(success) GC.enable(), but then to make sure there will be no
exception which will cause GC.enable to be skiped, we will make entire
thread_attachThis nothrow.1 parent f9276a7 commit 1e75c50
1 file changed
+1
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2073 | 2073 | | |
2074 | 2074 | | |
2075 | 2075 | | |
2076 | | - | |
| 2076 | + | |
2077 | 2077 | | |
2078 | 2078 | | |
2079 | 2079 | | |
| |||
0 commit comments