mirror of
https://github.com/RetroDECK/Duckstation.git
synced 2024-11-22 13:55:38 +00:00
Common: unused-result warning fix
This commit is contained in:
parent
56d95c3331
commit
fc96c2f656
|
@ -72,8 +72,7 @@ ALWAYS_INLINE static void* AlignedMalloc(size_t size, size_t alignment)
|
|||
size = (size + alignment - 1) & ~(alignment - 1);
|
||||
#endif
|
||||
void* ret = nullptr;
|
||||
posix_memalign(&ret, alignment, size);
|
||||
return ret;
|
||||
return (posix_memalign(&ret, alignment, size) == 0) ? ret : nullptr;
|
||||
#endif
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue