diff options
author | charlydoes <charlydoes@svn> | 2010-01-16 20:14:40 +0000 |
---|---|---|
committer | charlydoes <charlydoes@svn> | 2010-01-16 20:14:40 +0000 |
commit | a10e03bf59f7cae87900cc9ca133ee4a688fd17e (patch) | |
tree | 30a8fc54c31ede827177af81e8aeb1995d53b4c4 | |
parent | 94905040429b6ae717a0b8d8969a7c3b7a62ce02 (diff) |
[WIN32] fixed: findfirst/next emu (fixes milkdrop presets).
git-svn-id: https://xbmc.svn.sourceforge.net/svnroot/xbmc/trunk@26918 568bbfeb-2a22-0410-94d2-cc84cf5bfa90
-rw-r--r-- | xbmc/cores/DllLoader/exports/emu_msvcrt.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/xbmc/cores/DllLoader/exports/emu_msvcrt.cpp b/xbmc/cores/DllLoader/exports/emu_msvcrt.cpp index cf52589bf9..ffb4a0f302 100644 --- a/xbmc/cores/DllLoader/exports/emu_msvcrt.cpp +++ b/xbmc/cores/DllLoader/exports/emu_msvcrt.cpp @@ -732,8 +732,9 @@ extern "C" if (size) data->name[size - 1] = '\0'; data->size = static_cast<_fsize_t>(vecDirsOpen[iDirSlot].items[0]->m_dwSize); - data->time_write = iDirSlot; // save for later lookups + data->time_write = 0; data->time_access = 0; + vecDirsOpen[iDirSlot].curr_index = 0; return (intptr_t)&vecDirsOpen[iDirSlot]; } vecDirsOpen[iDirSlot].curr_index = -1; @@ -773,7 +774,7 @@ extern "C" return _findnext64i32(f, data); // local dir // we have a valid data struture. get next item! - int iItem=(int)data->time_access; + int iItem = vecDirsOpen[found].curr_index; if (iItem+1 < vecDirsOpen[found].items.Size()) // we have a winner! { int size = sizeof(data->name); @@ -781,7 +782,7 @@ extern "C" if (size) data->name[size - 1] = '\0'; data->size = static_cast<_fsize_t>(vecDirsOpen[found].items[iItem+1]->m_dwSize); - data->time_access++; + vecDirsOpen[found].curr_index++; return 0; } |