loader: Move NSO module tracking to AppLoader

Also cleanup of general stuff
This commit is contained in:
Zach Hilman 2019-05-26 11:40:41 -04:00
parent cdf52b9374
commit b77fde7c5c
22 changed files with 147 additions and 80 deletions

View file

@ -37,17 +37,18 @@ AppletDataBroker::~AppletDataBroker() = default;
AppletDataBroker::RawChannelData AppletDataBroker::PeekDataToAppletForDebug() const {
std::vector<std::vector<u8>> out_normal;
std::vector<std::vector<u8>> out_interactive;
for (const auto& storage : in_channel) {
out_normal.push_back(storage->GetData());
}
std::vector<std::vector<u8>> out_interactive;
for (const auto& storage : in_interactive_channel) {
out_interactive.push_back(storage->GetData());
}
return {out_normal, out_interactive};
return {std::move(out_normal), std::move(out_interactive)};
}
std::unique_ptr<IStorage> AppletDataBroker::PopNormalDataToGame() {

View file

@ -34,7 +34,7 @@ private:
class StubApplet final : public Applet {
public:
StubApplet(AppletId id);
explicit StubApplet(AppletId id);
~StubApplet() override;
void Initialize() override;

View file

@ -50,7 +50,7 @@ private:
void SaveReportWithUserOld(Kernel::HLERequestContext& ctx) {
IPC::RequestParser rp{ctx};
const auto user_id = rp.PopRaw<u128>();
const auto unk1 = rp.PopRaw<u64>();
const auto process_id = rp.PopRaw<u64>();
const auto data1 = ctx.ReadBuffer(0);
const auto data2 = ctx.ReadBuffer(1);
@ -58,10 +58,10 @@ private:
LOG_DEBUG(
Service_PREPO,
"called, user_id={:016X}{:016X}, unk1={:016X}, data1_size={:016X}, data2_size={:016X}",
user_id[1], user_id[0], unk1, data1.size(), data2.size());
user_id[1], user_id[0], process_id, data1.size(), data2.size());
const auto& reporter{Core::System::GetInstance().GetReporter()};
reporter.SavePlayReport(Core::CurrentProcess()->GetTitleID(), unk1, {data1, data2},
reporter.SavePlayReport(Core::CurrentProcess()->GetTitleID(), process_id, {data1, data2},
user_id);
IPC::ResponseBuilder rb{ctx, 2};