column_family_test: EnvCounter::num_new_writable_file_ to be atomic

Summary:
TSAN shows warning of data race of EnvCounter::num_new_writable_file_. Make it atomic.
Closes https://github.com/facebook/rocksdb/pull/2331

Differential Revision: D5089215

Pulled By: siying

fbshipit-source-id: 15f6dcfb770a3310cbb6337c22482c8b330daffc
main
Siying Dong 8 years ago committed by Facebook Github Bot
parent 9f839a7f62
commit 217b866f47
  1. 2
      db/column_family_test.cc

@ -55,7 +55,7 @@ class EnvCounter : public EnvWrapper {
} }
private: private:
int num_new_writable_file_; std::atomic<int> num_new_writable_file_;
}; };
class ColumnFamilyTest : public testing::Test { class ColumnFamilyTest : public testing::Test {

Loading…
Cancel
Save