Added a magic value to XE_SWAP packets to make it obvious if there's an opcode collision.

This commit is contained in:
gibbed
2015-05-29 14:34:37 -05:00
parent aee205101b
commit 35bea36fc4
2 changed files with 8 additions and 4 deletions

View File

@@ -946,10 +946,13 @@ bool CommandProcessor::ExecutePacketType3_XE_SWAP(RingbufferReader* 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->Read();
assert_true(magic == 'SWAP');
uint32_t frontbuffer_ptr = reader->Read();
uint32_t frontbuffer_width = reader->Read();
uint32_t frontbuffer_height = reader->Read();
reader->Advance(count - 3);
reader->Advance(count - 4);
last_swap_width_ = frontbuffer_width;
last_swap_height_ = frontbuffer_height;