| author | |
| committer | |
| log | 4f7d76f19ca2fcb18b47f0d07c3dc1ceaab0b6f2 |
| tree | b0161cb62644f2501a2ff1b1aa04e33f1217893e |
| parent | 15278b7f4b74e659fd968571cb9b96929da3d82c |
This bug caused the compiler to deadlock when multiple c objects
were build in parallel.
Thanks @kprotty for finding this bug!2 files changed, 6 insertions(+), 2 deletions(-)
lib/std/Progress.zig+5-1| ... | ... | @@ -103,7 +103,11 @@ pub const Node = struct { |
| 103 | 103 | } |
| 104 | 104 | parent.completeOne(); |
| 105 | 105 | } else { |
| 106 | self.context.done = true; | |
| 106 | { | |
| 107 | const held = self.context.update_lock.acquire(); | |
| 108 | defer held.release(); | |
| 109 | self.context.done = true; | |
| 110 | } | |
| 107 | 111 | self.context.refresh(); |
| 108 | 112 | } |
| 109 | 113 | } |
lib/std/os/windows/kernel32.zig+1-1| ... | ... | @@ -299,6 +299,6 @@ pub extern "kernel32" fn SleepConditionVariableSRW( |
| 299 | 299 | f: ULONG, |
| 300 | 300 | ) callconv(WINAPI) BOOL; |
| 301 | 301 | |
| 302 | pub extern "kernel32" fn TryAcquireSRWLockExclusive(s: *SRWLOCK) callconv(WINAPI) BOOL; | |
| 302 | pub extern "kernel32" fn TryAcquireSRWLockExclusive(s: *SRWLOCK) callconv(WINAPI) BOOLEAN; | |
| 303 | 303 | pub extern "kernel32" fn AcquireSRWLockExclusive(s: *SRWLOCK) callconv(WINAPI) void; |
| 304 | 304 | pub extern "kernel32" fn ReleaseSRWLockExclusive(s: *SRWLOCK) callconv(WINAPI) void; |