Navigation Menu

Skip to content

Commit

Permalink
cellGame: fix some installation issues
Browse files Browse the repository at this point in the history
fixes HAWX2 (at least until it crashes again)
  • Loading branch information
Megamouse committed Jan 9, 2019
1 parent d7cd280 commit 120acaf
Showing 1 changed file with 14 additions and 1 deletion.
15 changes: 14 additions & 1 deletion rpcs3/Emu/Cell/Modules/cellGame.cpp
Expand Up @@ -833,11 +833,24 @@ error_code cellGameGetSizeKB(vm::ptr<s32> size)
return CELL_GAME_ERROR_FAILURE;
}

if (Emu.GetCat() == "DG")
{
return CELL_GAME_ERROR_NOTSUPPORTED;
}

const std::string local_dir = !prm->temp.empty() ? prm->temp : vfs::get("/dev_hdd0/game/" + prm->dir);

if (!fs::is_dir(local_dir))
{
return CELL_GAME_ERROR_ACCESS_ERROR;
if (fs::is_file(local_dir))
{
return CELL_GAME_ERROR_ACCESS_ERROR;
}
else
{
*size = 0;
return CELL_OK;
}
}

*size = ::narrow<u32>(fs::get_dir_size(local_dir) / 1024);
Expand Down

0 comments on commit 120acaf

Please sign in to comment.