Skip to content

Commit

Permalink
fixup! Make worker state variable threadsafe
Browse files Browse the repository at this point in the history
  • Loading branch information
JamesWrigley committed Jul 25, 2024
1 parent 01c33e9 commit abafb79
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions test/threads.jl
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,8 @@ isfailed(rr) = fetch_from_owner(istaskfailed, rr)
# timedwait() instead of @sync to avoid deadlocks.
t1 = Threads.@spawn fetch_from_owner(wait, recv)
t2 = Threads.@spawn fetch_from_owner(wait, send)
@test timedwait(() -> istaskdone(t1), 5) == :ok
@test timedwait(() -> istaskdone(t2), 5) == :ok
@test timedwait(() -> istaskdone(t1), 60) == :ok
@test timedwait(() -> istaskdone(t2), 60) == :ok

# Check the tasks
@test isdone(send)
Expand Down

0 comments on commit abafb79

Please sign in to comment.