about summary refs log tree commit diff
path: root/src/rustllvm/RustWrapper.cpp
diff options
context:
space:
mode:
authorPietro Albini <pietro@pietroalbini.org>2019-03-08 09:41:50 +0100
committerGitHub <noreply@github.com>2019-03-08 09:41:50 +0100
commit4bff63f05ff0108d5dd083d6a865003cb69e075b (patch)
tree6cca20b505468fc41aa84e7b8ce931aa25c3e682 /src/rustllvm/RustWrapper.cpp
parent9c995110c4ecaedd9528f6a2fa872024c6d0701d (diff)
parent2293d2260a382146fe5ea62ce91580ad7a31178d (diff)
downloadrust-4bff63f05ff0108d5dd083d6a865003cb69e075b.tar.gz
rust-4bff63f05ff0108d5dd083d6a865003cb69e075b.zip
Rollup merge of #58893 - benaryorg:thread_local_example_join, r=alexcrichton
race condition in thread local storage example

The example had a potential race condition that would still pass the test.
If the thread which was supposed to modify it's own thread local was slower than the instruction to
modify in the main thread, then the test would pass even in case of a failure.
This is would be minor if the child thread was waited for since it check using an `assert_eq` for the
same thing, but vice versa.
However, if the `assert_eq` failed this would trigger a panic, which is not at all caught by the
example since the thread is not waited on.

Signed-off-by: benaryorg <binary@benary.org>
Diffstat (limited to 'src/rustllvm/RustWrapper.cpp')
0 files changed, 0 insertions, 0 deletions