MCPcopy Create free account
hub / github.com/PCSX2/pcsx2 / DoBytes

Method DoBytes

pcsx2/StateWrapper.cpp:20–32  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

18StateWrapper::~StateWrapper() = default;
19
20void StateWrapper::DoBytes(void* data, size_t length)
21{
22 if (m_mode == Mode::Read)
23 {
24 if (m_error || (m_error |= (m_stream->Read(data, static_cast<u32>(length)) != static_cast<u32>(length))) == true)
25 std::memset(data, 0, length);
26 }
27 else
28 {
29 if (!m_error)
30 m_error |= (m_stream->Write(data, static_cast<u32>(length)) != static_cast<u32>(length));
31 }
32}
33
34void StateWrapper::Do(bool* value_ptr)
35{

Callers 4

DoDeviceStateMethod · 0.80
FreezeMethod · 0.80
FreezeMethod · 0.80
DoStateMethod · 0.80

Calls 2

ReadMethod · 0.45
WriteMethod · 0.45

Tested by

no test coverage detected