Patches: Make cheats_ws.zip search case insensitive

This commit is contained in:
refractionpcsx2 2022-05-28 01:09:32 +01:00
parent 66c6c2400a
commit 43b53df0a0
1 changed files with 3 additions and 3 deletions

View File

@ -82,13 +82,13 @@ template<typename T>
static inline std::optional<T> ReadFileInZipToContainer(zip_t* zip, const char* name)
{
std::optional<T> ret;
const zip_int64_t file_index = zip_name_locate(zip, name, 0);
const zip_int64_t file_index = zip_name_locate(zip, name, ZIP_FL_NOCASE);
if (file_index >= 0)
{
zip_stat_t zst;
if (zip_stat_index(zip, file_index, 0, &zst) == 0)
if (zip_stat_index(zip, file_index, ZIP_FL_NOCASE, &zst) == 0)
{
zip_file_t* zf = zip_fopen_index(zip, file_index, 0);
zip_file_t* zf = zip_fopen_index(zip, file_index, ZIP_FL_NOCASE);
if (zf)
{
ret = T();