mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-07-25 00:04:49 +02:00
Remove usage of deprecated function readdir_r (and ugly Blackberry hack diren_large)
This commit is contained in:
@@ -66,9 +66,6 @@ static bool FixFilenameCase(const std::string &path, std::string &filename)
|
||||
}
|
||||
|
||||
//TODO: lookup filename in cache for "path"
|
||||
|
||||
struct dirent_large { struct dirent entry; char padding[FILENAME_MAX+1]; } diren;
|
||||
struct dirent_large;
|
||||
struct dirent *result = NULL;
|
||||
|
||||
DIR *dirp = opendir(path.c_str());
|
||||
@@ -77,7 +74,7 @@ static bool FixFilenameCase(const std::string &path, std::string &filename)
|
||||
|
||||
bool retValue = false;
|
||||
|
||||
while (!readdir_r(dirp, (dirent*) &diren, &result) && result)
|
||||
while ((result = readdir(dirp)))
|
||||
{
|
||||
if (strlen(result->d_name) != filenameSize)
|
||||
continue;
|
||||
|
||||
Reference in New Issue
Block a user