better thread safety
test that exploited a threading issue