Refactor FourCC magic uses

- Use new fourcc_t type
- Improves compiler compatibility by removing multi chars
This commit is contained in:
Joel Linn
2021-05-06 18:46:43 +02:00
committed by Rick Gibbed
parent 4daa3f5a52
commit a86d7173e1
25 changed files with 65 additions and 42 deletions

View File

@@ -824,8 +824,8 @@ bool CommandProcessor::ExecutePacketType3_XE_SWAP(RingBuffer* reader,
// VdSwap will post this to tell us we need to swap the screen/fire an
// interrupt.
// 63 words here, but only the first has any data.
uint32_t magic = reader->ReadAndSwap<uint32_t>();
assert_true(magic == 'SWAP');
uint32_t magic = reader->ReadAndSwap<fourcc_t>();
assert_true(magic == kSwapSignature);
// TODO(benvanik): only swap frontbuffer ptr.
uint32_t frontbuffer_ptr = reader->ReadAndSwap<uint32_t>();