aboutsummaryrefslogtreecommitdiff
path: root/src/leveldb/port/port_win.cc
diff options
context:
space:
mode:
authorPieter Wuille <pieter.wuille@gmail.com>2012-09-04 23:01:03 +0200
committerPieter Wuille <pieter.wuille@gmail.com>2012-10-20 23:08:56 +0200
commit9f56678fceef0a53411bdfcac82ab65f7b896838 (patch)
tree23b1e40a31e0177beb6ab65d06e4458d6feb04af /src/leveldb/port/port_win.cc
parent9d503a72855167fcfa66362657d3f93f7b823774 (diff)
Backport Win32 LevelDB env from C++0x to C++
Since the gitian mingw compiler doesn't support C++0x yet.
Diffstat (limited to 'src/leveldb/port/port_win.cc')
-rw-r--r--src/leveldb/port/port_win.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/leveldb/port/port_win.cc b/src/leveldb/port/port_win.cc
index 4ca64acbef..786cd6018a 100644
--- a/src/leveldb/port/port_win.cc
+++ b/src/leveldb/port/port_win.cc
@@ -134,7 +134,7 @@ AtomicPointer::AtomicPointer(void* v) {
}
void* AtomicPointer::Acquire_Load() const {
- void * p = nullptr;
+ void * p = NULL;
InterlockedExchangePointer(&p, rep_);
return p;
}
@@ -160,7 +160,7 @@ enum InitializationState
void InitOnce(OnceType* once, void (*initializer)()) {
- static_assert(Uninitialized == LEVELDB_ONCE_INIT, "Invalid uninitialized state value");
+ assert(Uninitialized == LEVELDB_ONCE_INIT);
InitializationState state = static_cast<InitializationState>(InterlockedCompareExchange(once, Running, Uninitialized));