GPU: Fix out-of-bounds read in GP1(10h)
This commit is contained in:
parent
24bda8f659
commit
b7209eafb1
|
@ -615,7 +615,7 @@ void GPU::WriteGP1(u32 value)
|
|||
case 0x1E:
|
||||
case 0x1F:
|
||||
{
|
||||
HandleGetGPUInfoCommand();
|
||||
HandleGetGPUInfoCommand(value);
|
||||
}
|
||||
break;
|
||||
|
||||
|
@ -625,9 +625,9 @@ void GPU::WriteGP1(u32 value)
|
|||
}
|
||||
}
|
||||
|
||||
void GPU::HandleGetGPUInfoCommand()
|
||||
void GPU::HandleGetGPUInfoCommand(u32 value)
|
||||
{
|
||||
const u8 subcommand = Truncate8(m_GP0_command[0] & 0x07);
|
||||
const u8 subcommand = Truncate8(value & 0x07);
|
||||
switch (subcommand)
|
||||
{
|
||||
case 0x00:
|
||||
|
|
|
@ -181,7 +181,7 @@ protected:
|
|||
u32 ReadGPUREAD();
|
||||
void WriteGP0(u32 value);
|
||||
void WriteGP1(u32 value);
|
||||
void HandleGetGPUInfoCommand();
|
||||
void HandleGetGPUInfoCommand(u32 value);
|
||||
|
||||
// Rendering commands, returns false if not enough data is provided
|
||||
bool HandleRenderCommand();
|
||||
|
|
Loading…
Reference in New Issue