Skip to content

Commit

Permalink
Checks for content_id in sceNpDrmVerifyUpgradeLicense and sceNpDrmVer…
Browse files Browse the repository at this point in the history
…ifyUpgradeLicense2
  • Loading branch information
scribam authored and AniLeo committed Feb 25, 2018
1 parent d78b046 commit aabf3c6
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions rpcs3/Emu/Cell/Modules/sceNp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,11 @@ s32 sceNpDrmVerifyUpgradeLicense(vm::cptr<char> content_id)
{
sceNp.warning("sceNpDrmVerifyUpgradeLicense(content_id=%s)", content_id);

if (!content_id)
{
return SCE_NP_DRM_ERROR_INVALID_PARAM;
}

if (!fs::is_file(vfs::get("/dev_hdd0/home/00000001/exdata/") + content_id.get_ptr() + ".rap"))
{
// Game hasn't been purchased therefore no RAP file present
Expand All @@ -154,6 +159,11 @@ s32 sceNpDrmVerifyUpgradeLicense2(vm::cptr<char> content_id)
{
sceNp.warning("sceNpDrmVerifyUpgradeLicense2(content_id=%s)", content_id);

if (!content_id)
{
return SCE_NP_DRM_ERROR_INVALID_PARAM;
}

if (!fs::is_file(vfs::get("/dev_hdd0/home/00000001/exdata/") + content_id.get_ptr() + ".rap"))
{
// Game hasn't been purchased therefore no RAP file present
Expand Down

0 comments on commit aabf3c6

Please sign in to comment.