strat: go all in on ncm::TitleId
This commit is contained in:
@@ -30,7 +30,7 @@ Result NsAmMitmService::GetApplicationContentPath(OutBuffer<u8> out_path, u64 ap
|
||||
|
||||
Result NsAmMitmService::ResolveApplicationContentPath(u64 title_id, u8 storage_type) {
|
||||
/* Always succeed for web applet asking about HBL. */
|
||||
if (Utils::IsWebAppletTid(this->title_id) && Utils::IsHblTid(title_id)) {
|
||||
if (Utils::IsWebAppletTid(static_cast<u64>(this->title_id)) && Utils::IsHblTid(title_id)) {
|
||||
nsamResolveApplicationContentPathFwd(this->forward_service.get(), title_id, static_cast<FsStorageId>(storage_type));
|
||||
return ResultSuccess;
|
||||
}
|
||||
|
||||
@@ -32,11 +32,11 @@ class NsAmMitmService : public IMitmServiceObject {
|
||||
/* ... */
|
||||
}
|
||||
|
||||
static bool ShouldMitm(u64 pid, u64 tid) {
|
||||
static bool ShouldMitm(u64 pid, sts::ncm::TitleId tid) {
|
||||
/* We will mitm:
|
||||
* - web applets, to facilitate hbl web browser launching.
|
||||
*/
|
||||
return Utils::IsWebAppletTid(tid);
|
||||
return Utils::IsWebAppletTid(static_cast<u64>(tid));
|
||||
}
|
||||
|
||||
static void PostProcess(IMitmServiceObject *obj, IpcResponseContext *ctx);
|
||||
|
||||
@@ -29,7 +29,7 @@ Result NsWebMitmService::GetDocumentInterface(Out<std::shared_ptr<NsDocumentServ
|
||||
R_TRY(nsGetDocumentInterfaceFwd(this->forward_service.get(), &doc));
|
||||
|
||||
/* Set output interface. */
|
||||
out_intf.SetValue(std::move(std::make_shared<NsDocumentService>(this->title_id, doc)));
|
||||
out_intf.SetValue(std::move(std::make_shared<NsDocumentService>(static_cast<u64>(this->title_id), doc)));
|
||||
if (out_intf.IsDomain()) {
|
||||
out_intf.ChangeObjectId(doc.s.object_id);
|
||||
}
|
||||
@@ -43,7 +43,7 @@ Result NsDocumentService::GetApplicationContentPath(OutBuffer<u8> out_path, u64
|
||||
|
||||
Result NsDocumentService::ResolveApplicationContentPath(u64 title_id, u8 storage_type) {
|
||||
/* Always succeed for web applet asking about HBL. */
|
||||
if (Utils::IsWebAppletTid(this->title_id) && Utils::IsHblTid(title_id)) {
|
||||
if (Utils::IsWebAppletTid(static_cast<u64>(this->title_id)) && Utils::IsHblTid(title_id)) {
|
||||
nswebResolveApplicationContentPath(this->srv.get(), title_id, static_cast<FsStorageId>(storage_type));
|
||||
return ResultSuccess;
|
||||
}
|
||||
|
||||
@@ -71,11 +71,11 @@ class NsWebMitmService : public IMitmServiceObject {
|
||||
/* ... */
|
||||
}
|
||||
|
||||
static bool ShouldMitm(u64 pid, u64 tid) {
|
||||
static bool ShouldMitm(u64 pid, sts::ncm::TitleId tid) {
|
||||
/* We will mitm:
|
||||
* - web applets, to facilitate hbl web browser launching.
|
||||
*/
|
||||
return Utils::IsWebAppletTid(tid);
|
||||
return Utils::IsWebAppletTid(static_cast<u64>(tid));
|
||||
}
|
||||
|
||||
static void PostProcess(IMitmServiceObject *obj, IpcResponseContext *ctx);
|
||||
|
||||
Reference in New Issue
Block a user