Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TSAN shows a data race in the unit tests #25

Open
jcjones opened this issue Aug 1, 2017 · 0 comments
Open

TSAN shows a data race in the unit tests #25

jcjones opened this issue Aug 1, 2017 · 0 comments

Comments

@jcjones
Copy link
Contributor

jcjones commented Aug 1, 2017

RUSTFLAGS="-Z sanitizer=thread" rustup run nightly cargo test

running 4 tests
test u2fprotocol::tests::test_init_device ... ok
test u2fprotocol::tests::test_ping_device ... ok
test u2fprotocol::tests::test_sendapdu ... ok
==================
WARNING: ThreadSanitizer: data race (pid=35046)
  Write of size 8 at 0x7e8000284070 by thread T4:
    #0 memmove <null>:65020504 (libclang_rt.tsan_osx_dynamic.dylib:x86_64+0xc206)
    #1 pthread_setname_np <null>:63970968 (libsystem_pthread.dylib:x86_64+0x421a)

  Previous write of size 8 at 0x7e8000284070 by thread T1:
    #0 memmove <null>:65020504 (libclang_rt.tsan_osx_dynamic.dylib:x86_64+0xc206)
    #1 pthread_setname_np <null>:63970968 (libsystem_pthread.dylib:x86_64+0x421a)

  Thread T4 (tid=5431922, running) created by main thread at:
    #0 pthread_create <null>:65020504 (libclang_rt.tsan_osx_dynamic.dylib:x86_64+0x7121)
    #1 std::sys::imp::thread::Thread::new::hb0ee40c469bc0ac1 thread.rs:72 (u2fhid-67c8d56994e664bc:x86_64+0x10006d575)
    #2 __rust_maybe_catch_panic lib.rs:98 (u2fhid-67c8d56994e664bc:x86_64+0x10007176c)
    #3 start <null>:63965880 (libdyld.dylib:x86_64+0x5234)

  Thread T1 (tid=5431919, finished) created by main thread at:
    #0 pthread_create <null>:65020504 (libclang_rt.tsan_osx_dynamic.dylib:x86_64+0x7121)
    #1 std::sys::imp::thread::Thread::new::hb0ee40c469bc0ac1 thread.rs:72 (u2fhid-67c8d56994e664bc:x86_64+0x10006d575)
    #2 __rust_maybe_catch_panic lib.rs:98 (u2fhid-67c8d56994e664bc:x86_64+0x10007176c)
    #3 start <null>:63965880 (libdyld.dylib:x86_64+0x5234)

SUMMARY: ThreadSanitizer: data race (libsystem_pthread.dylib:x86_64+0x421a) in pthread_setname_np
==================
test u2fprotocol::tests::test_sendrecv_multiple ... ok

test result: ok. 4 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out
@jcjones jcjones modified the milestone: Long Term Goals Aug 11, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant