mirror of
https://github.com/ElementsProject/elements.git
synced 2026-08-14 12:43:40 +02:00
Fixing compiler warning C4800: 'type' forcing value to bool 'true' or 'false'
This commit is contained in:
parent
b8d92236f6
commit
8d657a6517
9 changed files with 23 additions and 23 deletions
|
|
@ -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
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue