aboutsummaryrefslogtreecommitdiff
path: root/src/allocators.cpp
diff options
context:
space:
mode:
authorPieter Wuille <pieter.wuille@gmail.com>2014-09-16 04:43:49 +0200
committerPieter Wuille <pieter.wuille@gmail.com>2014-09-16 04:47:55 +0200
commitdc54e9db982118ec71cc11b8d027e5a569810cba (patch)
tree34b0ca1ab9f4c153a551750dae6fea3b2dbf286a /src/allocators.cpp
parent7388b74cd2c5e3b71e991d26953c89c059ba6f2f (diff)
parent8d657a651735426388c5f7462e2dbf24225a26cb (diff)
Merge pull request #4825
8d657a6 Fixing compiler warning C4800: 'type' forcing value to bool 'true' or 'false' (ENikS)
Diffstat (limited to 'src/allocators.cpp')
-rw-r--r--src/allocators.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/allocators.cpp b/src/allocators.cpp
index 15f34aa2c8..8ecd7206cd 100644
--- a/src/allocators.cpp
+++ b/src/allocators.cpp
@@ -46,7 +46,7 @@ static inline size_t GetSystemPageSize()
bool MemoryPageLocker::Lock(const void *addr, size_t len)
{
#ifdef WIN32
- return VirtualLock(const_cast<void*>(addr), len);
+ return VirtualLock(const_cast<void*>(addr), len) != 0;
#else
return mlock(addr, len) == 0;
#endif
@@ -55,7 +55,7 @@ bool MemoryPageLocker::Lock(const void *addr, size_t len)
bool MemoryPageLocker::Unlock(const void *addr, size_t len)
{
#ifdef WIN32
- return VirtualUnlock(const_cast<void*>(addr), len);
+ return VirtualUnlock(const_cast<void*>(addr), len) != 0;
#else
return munlock(addr, len) == 0;
#endif