recording: Fix console logging for file read and write errors

This commit is contained in:
sonicfind 2020-12-25 18:59:23 -06:00 committed by refractionpcsx2
parent a1b6f0b76a
commit 3f359147c8
1 changed files with 2 additions and 2 deletions

View File

@ -111,7 +111,7 @@ void InputRecording::ControllerInterrupt(u8& data, u8& port, u16& bufCount, u8 b
if (frameCounter >= 0 && frameCounter < INT_MAX) if (frameCounter >= 0 && frameCounter < INT_MAX)
{ {
if (!inputRecordingData.ReadKeyBuffer(bufVal, frameCounter, port, bufIndex)) if (!inputRecordingData.ReadKeyBuffer(bufVal, frameCounter, port, bufIndex))
inputRec::consoleLog(fmt::format("[REC]: Failed to read input data at frame {}", frameCounter)); inputRec::consoleLog(fmt::format("Failed to read input data at frame {}", frameCounter));
// Update controller data state for future VirtualPad / logging usage. // Update controller data state for future VirtualPad / logging usage.
padData[port]->UpdateControllerData(bufIndex, bufVal); padData[port]->UpdateControllerData(bufIndex, bufVal);
@ -142,7 +142,7 @@ void InputRecording::ControllerInterrupt(u8& data, u8& port, u16& bufCount, u8 b
} }
if (frameCounter < INT_MAX && !inputRecordingData.WriteKeyBuffer(frameCounter, port, bufIndex, bufVal)) if (frameCounter < INT_MAX && !inputRecordingData.WriteKeyBuffer(frameCounter, port, bufIndex, bufVal))
inputRec::consoleLog(fmt::format("[REC]: Failed to write input data at frame {}", frameCounter)); inputRec::consoleLog(fmt::format("Failed to write input data at frame {}", frameCounter));
} }
} }
// If the VirtualPad updated the PadData, we have to update the buffer // If the VirtualPad updated the PadData, we have to update the buffer