diff options
author | Lioncash <mathew1800@gmail.com> | 2018-10-10 06:42:10 +0200 |
---|---|---|
committer | Lioncash <mathew1800@gmail.com> | 2018-10-10 08:04:55 +0200 |
commit | 5c0408596f6ccf5d2b171321bac386713b169d5b (patch) | |
tree | 1c5d3e1b178d7252cd3e752d8f2a99017a0ecb6d /src/core/core.cpp | |
parent | Merge pull request #1461 from lioncash/warn (diff) | |
download | yuzu-5c0408596f6ccf5d2b171321bac386713b169d5b.tar yuzu-5c0408596f6ccf5d2b171321bac386713b169d5b.tar.gz yuzu-5c0408596f6ccf5d2b171321bac386713b169d5b.tar.bz2 yuzu-5c0408596f6ccf5d2b171321bac386713b169d5b.tar.lz yuzu-5c0408596f6ccf5d2b171321bac386713b169d5b.tar.xz yuzu-5c0408596f6ccf5d2b171321bac386713b169d5b.tar.zst yuzu-5c0408596f6ccf5d2b171321bac386713b169d5b.zip |
Diffstat (limited to '')
-rw-r--r-- | src/core/core.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/core/core.cpp b/src/core/core.cpp index b6acfb3e4..e2fb9e038 100644 --- a/src/core/core.cpp +++ b/src/core/core.cpp @@ -136,7 +136,8 @@ struct System::Impl { if (virtual_filesystem == nullptr) virtual_filesystem = std::make_shared<FileSys::RealVfsFilesystem>(); - kernel.MakeCurrentProcess(Kernel::Process::Create(kernel, "main")); + auto main_process = Kernel::Process::Create(kernel, "main"); + kernel.MakeCurrentProcess(main_process.get()); cpu_barrier = std::make_shared<CpuBarrier>(); cpu_exclusive_monitor = Cpu::MakeExclusiveMonitor(cpu_cores.size()); @@ -361,11 +362,11 @@ const std::shared_ptr<Kernel::Scheduler>& System::Scheduler(std::size_t core_ind return impl->cpu_cores[core_index]->Scheduler(); } -Kernel::SharedPtr<Kernel::Process>& System::CurrentProcess() { +Kernel::Process* System::CurrentProcess() { return impl->kernel.CurrentProcess(); } -const Kernel::SharedPtr<Kernel::Process>& System::CurrentProcess() const { +const Kernel::Process* System::CurrentProcess() const { return impl->kernel.CurrentProcess(); } |