summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/core/hle/service/acc/acc.cpp13
-rw-r--r--src/core/hle/service/acc/async_context.cpp12
-rw-r--r--src/core/hle/service/acc/async_context.h4
3 files changed, 14 insertions, 15 deletions
diff --git a/src/core/hle/service/acc/acc.cpp b/src/core/hle/service/acc/acc.cpp
index 1db054257..6d9ec0a8a 100644
--- a/src/core/hle/service/acc/acc.cpp
+++ b/src/core/hle/service/acc/acc.cpp
@@ -491,7 +491,7 @@ public:
491 491
492class EnsureTokenIdCacheAsyncInterface final : public IAsyncContext { 492class EnsureTokenIdCacheAsyncInterface final : public IAsyncContext {
493public: 493public:
494 explicit EnsureTokenIdCacheAsyncInterface(Core::System& system_) : IAsyncContext(system_) { 494 explicit EnsureTokenIdCacheAsyncInterface(Core::System& system_) : IAsyncContext{system_} {
495 MarkComplete(); 495 MarkComplete();
496 } 496 }
497 ~EnsureTokenIdCacheAsyncInterface() = default; 497 ~EnsureTokenIdCacheAsyncInterface() = default;
@@ -504,13 +504,13 @@ public:
504 } 504 }
505 505
506protected: 506protected:
507 bool IsComplete() override { 507 bool IsComplete() const override {
508 return true; 508 return true;
509 } 509 }
510 510
511 void Cancel() override {} 511 void Cancel() override {}
512 512
513 ResultCode GetResult() override { 513 ResultCode GetResult() const override {
514 return ResultSuccess; 514 return ResultSuccess;
515 } 515 }
516}; 516};
@@ -518,7 +518,9 @@ protected:
518class IManagerForApplication final : public ServiceFramework<IManagerForApplication> { 518class IManagerForApplication final : public ServiceFramework<IManagerForApplication> {
519public: 519public:
520 explicit IManagerForApplication(Core::System& system_, Common::UUID user_id_) 520 explicit IManagerForApplication(Core::System& system_, Common::UUID user_id_)
521 : ServiceFramework{system_, "IManagerForApplication"}, user_id{user_id_}, system(system_) { 521 : ServiceFramework{system_, "IManagerForApplication"},
522 ensure_token_id{std::make_shared<EnsureTokenIdCacheAsyncInterface>(system)},
523 user_id{user_id_} {
522 // clang-format off 524 // clang-format off
523 static const FunctionInfo functions[] = { 525 static const FunctionInfo functions[] = {
524 {0, &IManagerForApplication::CheckAvailability, "CheckAvailability"}, 526 {0, &IManagerForApplication::CheckAvailability, "CheckAvailability"},
@@ -533,8 +535,6 @@ public:
533 // clang-format on 535 // clang-format on
534 536
535 RegisterHandlers(functions); 537 RegisterHandlers(functions);
536
537 ensure_token_id = std::make_shared<EnsureTokenIdCacheAsyncInterface>(system);
538 } 538 }
539 539
540private: 540private:
@@ -591,7 +591,6 @@ private:
591 591
592 std::shared_ptr<EnsureTokenIdCacheAsyncInterface> ensure_token_id{}; 592 std::shared_ptr<EnsureTokenIdCacheAsyncInterface> ensure_token_id{};
593 Common::UUID user_id{Common::INVALID_UUID}; 593 Common::UUID user_id{Common::INVALID_UUID};
594 Core::System& system;
595}; 594};
596 595
597// 6.0.0+ 596// 6.0.0+
diff --git a/src/core/hle/service/acc/async_context.cpp b/src/core/hle/service/acc/async_context.cpp
index a9a8888ed..f7a7e34ea 100644
--- a/src/core/hle/service/acc/async_context.cpp
+++ b/src/core/hle/service/acc/async_context.cpp
@@ -14,12 +14,12 @@ IAsyncContext::IAsyncContext(Core::System& system_)
14 compeletion_event.Initialize("IAsyncContext:CompletionEvent"); 14 compeletion_event.Initialize("IAsyncContext:CompletionEvent");
15 15
16 // clang-format off 16 // clang-format off
17 static const FunctionInfo functions[] = { 17 static const FunctionInfo functions[] = {
18 {0, &IAsyncContext::GetSystemEvent, "GetSystemEvent"}, 18 {0, &IAsyncContext::GetSystemEvent, "GetSystemEvent"},
19 {1, &IAsyncContext::Cancel, "Cancel"}, 19 {1, &IAsyncContext::Cancel, "Cancel"},
20 {2, &IAsyncContext::HasDone, "HasDone"}, 20 {2, &IAsyncContext::HasDone, "HasDone"},
21 {3, &IAsyncContext::GetResult, "GetResult"}, 21 {3, &IAsyncContext::GetResult, "GetResult"},
22 }; 22 };
23 // clang-format on 23 // clang-format on
24 24
25 RegisterHandlers(functions); 25 RegisterHandlers(functions);
diff --git a/src/core/hle/service/acc/async_context.h b/src/core/hle/service/acc/async_context.h
index 2453a79f5..6592326d0 100644
--- a/src/core/hle/service/acc/async_context.h
+++ b/src/core/hle/service/acc/async_context.h
@@ -23,9 +23,9 @@ public:
23 void GetResult(Kernel::HLERequestContext& ctx); 23 void GetResult(Kernel::HLERequestContext& ctx);
24 24
25protected: 25protected:
26 virtual bool IsComplete() = 0; 26 virtual bool IsComplete() const = 0;
27 virtual void Cancel() = 0; 27 virtual void Cancel() = 0;
28 virtual ResultCode GetResult() = 0; 28 virtual ResultCode GetResult() const = 0;
29 29
30 void MarkComplete(); 30 void MarkComplete();
31 31