diff options
| author | 2019-09-22 11:49:36 +1000 | |
|---|---|---|
| committer | 2019-09-22 11:49:36 +1000 | |
| commit | a1b8e5d09a3a38f7d29c2d10985a444dde4faea8 (patch) | |
| tree | 317c2d3ddd68449722c4c3f3f32273e07e49d953 /src/core/reporter.cpp | |
| parent | Merge pull request #2430 from DarkLordZach/fs-controller (diff) | |
| parent | prepo: Remove system global accessors (diff) | |
| download | yuzu-a1b8e5d09a3a38f7d29c2d10985a444dde4faea8.tar.gz yuzu-a1b8e5d09a3a38f7d29c2d10985a444dde4faea8.tar.xz yuzu-a1b8e5d09a3a38f7d29c2d10985a444dde4faea8.zip | |
Merge pull request #2612 from DarkLordZach/prepo-new
prepo: Implement New, System, and Non-User variants of SaveReport
Diffstat (limited to 'src/core/reporter.cpp')
| -rw-r--r-- | src/core/reporter.cpp | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/src/core/reporter.cpp b/src/core/reporter.cpp index cfe0771e2..9c657929e 100644 --- a/src/core/reporter.cpp +++ b/src/core/reporter.cpp | |||
| @@ -304,8 +304,8 @@ void Reporter::SaveUnimplementedAppletReport( | |||
| 304 | SaveToFile(std::move(out), GetPath("unimpl_applet_report", title_id, timestamp)); | 304 | SaveToFile(std::move(out), GetPath("unimpl_applet_report", title_id, timestamp)); |
| 305 | } | 305 | } |
| 306 | 306 | ||
| 307 | void Reporter::SavePlayReport(u64 title_id, u64 process_id, std::vector<std::vector<u8>> data, | 307 | void Reporter::SavePlayReport(PlayReportType type, u64 title_id, std::vector<std::vector<u8>> data, |
| 308 | std::optional<u128> user_id) const { | 308 | std::optional<u64> process_id, std::optional<u128> user_id) const { |
| 309 | if (!IsReportingEnabled()) { | 309 | if (!IsReportingEnabled()) { |
| 310 | return; | 310 | return; |
| 311 | } | 311 | } |
| @@ -321,7 +321,11 @@ void Reporter::SavePlayReport(u64 title_id, u64 process_id, std::vector<std::vec | |||
| 321 | data_out.push_back(Common::HexToString(d)); | 321 | data_out.push_back(Common::HexToString(d)); |
| 322 | } | 322 | } |
| 323 | 323 | ||
| 324 | out["play_report_process_id"] = fmt::format("{:016X}", process_id); | 324 | if (process_id.has_value()) { |
| 325 | out["play_report_process_id"] = fmt::format("{:016X}", *process_id); | ||
| 326 | } | ||
| 327 | |||
| 328 | out["play_report_type"] = fmt::format("{:02}", static_cast<u8>(type)); | ||
| 325 | out["play_report_data"] = std::move(data_out); | 329 | out["play_report_data"] = std::move(data_out); |
| 326 | 330 | ||
| 327 | SaveToFile(std::move(out), GetPath("play_report", title_id, timestamp)); | 331 | SaveToFile(std::move(out), GetPath("play_report", title_id, timestamp)); |