6ed4431d8b
It's undefined behavior to pass a null pointer to std::fread and std::fwrite, even if the length passed in is zero, so we must perform the precondition checking ourselves. A common case where this can occur is when passing in the data of an empty std::vector and size, as an empty vector will typically have a null internal buffer. While we're at it, we can move the implementation out of line and add debug checks against passing in nullptr to std::fread and std::fwrite. |
||
---|---|---|
.. | ||
android | ||
audio_core | ||
citra | ||
citra_qt | ||
common | ||
core | ||
dedicated_room | ||
input_common | ||
network | ||
tests | ||
video_core | ||
web_service | ||
.clang-format | ||
CMakeLists.txt |