summaryrefslogtreecommitdiffstats
path: root/src/core/hle/kernel/shared_memory.cpp
diff options
context:
space:
mode:
authorbunnei <bunneidev@gmail.com>2019-11-25 02:15:51 +0100
committerGitHub <noreply@github.com>2019-11-25 02:15:51 +0100
commit9046d4a5485452802b756869b7d27056ba9ea9d7 (patch)
tree2d704d912e9054fb232b73ad69f1bc3966ed97a5 /src/core/hle/kernel/shared_memory.cpp
parentMerge pull request #3098 from ReinUsesLisp/shader-invalidations (diff)
downloadyuzu-9046d4a5485452802b756869b7d27056ba9ea9d7.tar
yuzu-9046d4a5485452802b756869b7d27056ba9ea9d7.tar.gz
yuzu-9046d4a5485452802b756869b7d27056ba9ea9d7.tar.bz2
yuzu-9046d4a5485452802b756869b7d27056ba9ea9d7.tar.lz
yuzu-9046d4a5485452802b756869b7d27056ba9ea9d7.tar.xz
yuzu-9046d4a5485452802b756869b7d27056ba9ea9d7.tar.zst
yuzu-9046d4a5485452802b756869b7d27056ba9ea9d7.zip
Diffstat (limited to '')
-rw-r--r--src/core/hle/kernel/shared_memory.cpp15
1 files changed, 8 insertions, 7 deletions
diff --git a/src/core/hle/kernel/shared_memory.cpp b/src/core/hle/kernel/shared_memory.cpp
index a815c4eea..afb2e3fc2 100644
--- a/src/core/hle/kernel/shared_memory.cpp
+++ b/src/core/hle/kernel/shared_memory.cpp
@@ -15,11 +15,12 @@ namespace Kernel {
SharedMemory::SharedMemory(KernelCore& kernel) : Object{kernel} {}
SharedMemory::~SharedMemory() = default;
-SharedPtr<SharedMemory> SharedMemory::Create(KernelCore& kernel, Process* owner_process, u64 size,
- MemoryPermission permissions,
- MemoryPermission other_permissions, VAddr address,
- MemoryRegion region, std::string name) {
- SharedPtr<SharedMemory> shared_memory(new SharedMemory(kernel));
+std::shared_ptr<SharedMemory> SharedMemory::Create(KernelCore& kernel, Process* owner_process,
+ u64 size, MemoryPermission permissions,
+ MemoryPermission other_permissions,
+ VAddr address, MemoryRegion region,
+ std::string name) {
+ std::shared_ptr<SharedMemory> shared_memory = std::make_shared<SharedMemory>(kernel);
shared_memory->owner_process = owner_process;
shared_memory->name = std::move(name);
@@ -58,10 +59,10 @@ SharedPtr<SharedMemory> SharedMemory::Create(KernelCore& kernel, Process* owner_
return shared_memory;
}
-SharedPtr<SharedMemory> SharedMemory::CreateForApplet(
+std::shared_ptr<SharedMemory> SharedMemory::CreateForApplet(
KernelCore& kernel, std::shared_ptr<Kernel::PhysicalMemory> heap_block, std::size_t offset,
u64 size, MemoryPermission permissions, MemoryPermission other_permissions, std::string name) {
- SharedPtr<SharedMemory> shared_memory(new SharedMemory(kernel));
+ std::shared_ptr<SharedMemory> shared_memory = std::make_shared<SharedMemory>(kernel);
shared_memory->owner_process = nullptr;
shared_memory->name = std::move(name);