From 07a2e579322565aad2c84fe7aadafab855380222 Mon Sep 17 00:00:00 2001 From: "Unknown W. Brackets" Date: Sun, 2 Mar 2014 13:47:11 -0800 Subject: [PATCH] Synchronize IO operations before any seek. To prevent it from seeking before the operation. --- Core/HLE/sceIo.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Core/HLE/sceIo.cpp b/Core/HLE/sceIo.cpp index 9492b72135..7bc429d52c 100644 --- a/Core/HLE/sceIo.cpp +++ b/Core/HLE/sceIo.cpp @@ -1024,6 +1024,11 @@ u32 npdrmLseek(FileNode *f, s32 where, FileMove whence) s64 __IoLseekDest(FileNode *f, s64 offset, int whence, FileMove &seek) { seek = FILEMOVE_BEGIN; + // Let's make sure this isn't incorrect mid-operation. + if (ioManager.HasOperation(f->handle)) { + ioManager.SyncThread(); + } + s64 newPos = 0; switch (whence) { case 0: