summaryrefslogtreecommitdiffstats
path: root/src/core/hle/service/apt
diff options
context:
space:
mode:
authorYuri Kunde Schlesner <yuriks@yuriks.net>2016-12-15 05:35:33 +0100
committerGitHub <noreply@github.com>2016-12-15 05:35:33 +0100
commit905fc92ce1f7d99d8819a17b180a559b3a9f15de (patch)
treecc992764c2ea065d8d30dce2055cc1efe167bc59 /src/core/hle/service/apt
parentMerge pull request #2166 from endrift/clang-detect (diff)
parentFixed the codestyle to match our clang-format rules. (diff)
downloadyuzu-905fc92ce1f7d99d8819a17b180a559b3a9f15de.tar
yuzu-905fc92ce1f7d99d8819a17b180a559b3a9f15de.tar.gz
yuzu-905fc92ce1f7d99d8819a17b180a559b3a9f15de.tar.bz2
yuzu-905fc92ce1f7d99d8819a17b180a559b3a9f15de.tar.lz
yuzu-905fc92ce1f7d99d8819a17b180a559b3a9f15de.tar.xz
yuzu-905fc92ce1f7d99d8819a17b180a559b3a9f15de.tar.zst
yuzu-905fc92ce1f7d99d8819a17b180a559b3a9f15de.zip
Diffstat (limited to 'src/core/hle/service/apt')
-rw-r--r--src/core/hle/service/apt/apt.h3
-rw-r--r--src/core/hle/service/apt/apt_a.cpp2
-rw-r--r--src/core/hle/service/apt/apt_s.cpp2
-rw-r--r--src/core/hle/service/apt/apt_u.cpp2
4 files changed, 6 insertions, 3 deletions
diff --git a/src/core/hle/service/apt/apt.h b/src/core/hle/service/apt/apt.h
index e6a8be870..80325361f 100644
--- a/src/core/hle/service/apt/apt.h
+++ b/src/core/hle/service/apt/apt.h
@@ -14,6 +14,9 @@ class Interface;
namespace APT {
+/// Each APT service can only have up to 2 sessions connected at the same time.
+static const u32 MaxAPTSessions = 2;
+
/// Holds information about the parameters used in Send/Glance/ReceiveParameter
struct MessageParameter {
u32 sender_id = 0;
diff --git a/src/core/hle/service/apt/apt_a.cpp b/src/core/hle/service/apt/apt_a.cpp
index 6e35e1d29..62dc2d61d 100644
--- a/src/core/hle/service/apt/apt_a.cpp
+++ b/src/core/hle/service/apt/apt_a.cpp
@@ -102,7 +102,7 @@ const Interface::FunctionInfo FunctionTable[] = {
{0x01050100, nullptr, "IsTitleAllowed"},
};
-APT_A_Interface::APT_A_Interface() {
+APT_A_Interface::APT_A_Interface() : Interface(MaxAPTSessions) {
Register(FunctionTable);
}
diff --git a/src/core/hle/service/apt/apt_s.cpp b/src/core/hle/service/apt/apt_s.cpp
index 84019e6e5..effd23dce 100644
--- a/src/core/hle/service/apt/apt_s.cpp
+++ b/src/core/hle/service/apt/apt_s.cpp
@@ -102,7 +102,7 @@ const Interface::FunctionInfo FunctionTable[] = {
{0x01050100, nullptr, "IsTitleAllowed"},
};
-APT_S_Interface::APT_S_Interface() {
+APT_S_Interface::APT_S_Interface() : Interface(MaxAPTSessions) {
Register(FunctionTable);
}
diff --git a/src/core/hle/service/apt/apt_u.cpp b/src/core/hle/service/apt/apt_u.cpp
index a731c39f6..e06084a1e 100644
--- a/src/core/hle/service/apt/apt_u.cpp
+++ b/src/core/hle/service/apt/apt_u.cpp
@@ -99,7 +99,7 @@ const Interface::FunctionInfo FunctionTable[] = {
{0x01020000, CheckNew3DS, "CheckNew3DS"},
};
-APT_U_Interface::APT_U_Interface() {
+APT_U_Interface::APT_U_Interface() : Interface(MaxAPTSessions) {
Register(FunctionTable);
}