mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-07-07 15:31:26 +12:00
utils/atomic.hpp: Make atomic_op reject non-non-const lvalue
This commit is contained in:
parent
1417f9b7de
commit
85d1649696
6 changed files with 45 additions and 15 deletions
|
@ -2698,7 +2698,7 @@ void spu_thread::do_dma_transfer(spu_thread* _this, const spu_mfc_cmd& args, u8*
|
|||
|
||||
bool ok = false;
|
||||
|
||||
std::tie(old, ok) = bits->fetch_op([&](auto& v)
|
||||
std::tie(old, ok) = bits->fetch_op([&](u128& v)
|
||||
{
|
||||
if (v & wmask)
|
||||
{
|
||||
|
@ -2796,7 +2796,7 @@ void spu_thread::do_dma_transfer(spu_thread* _this, const spu_mfc_cmd& args, u8*
|
|||
res += 127;
|
||||
|
||||
// Release bits and notify
|
||||
bits->atomic_op([&](auto& v)
|
||||
bits->atomic_op([&](u128& v)
|
||||
{
|
||||
v &= ~wmask;
|
||||
});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue