diff --git a/libraries/libvapours/include/vapours/util/util_uuid.hpp b/libraries/libvapours/include/vapours/util/util_uuid.hpp index 60bb724c5..d3f19a955 100644 --- a/libraries/libvapours/include/vapours/util/util_uuid.hpp +++ b/libraries/libvapours/include/vapours/util/util_uuid.hpp @@ -15,8 +15,8 @@ */ #pragma once -#include -#include +#include +#include namespace ams::util { diff --git a/stratosphere/ncm/source/lr_addoncontentlocationresolver.cpp b/stratosphere/ncm/source/lr_addoncontentlocationresolver.cpp index 1d19d9556..5e9aa0524 100644 --- a/stratosphere/ncm/source/lr_addoncontentlocationresolver.cpp +++ b/stratosphere/ncm/source/lr_addoncontentlocationresolver.cpp @@ -34,7 +34,7 @@ namespace ams::lr { std::shared_ptr content_storage; R_TRY(ncm::impl::OpenContentStorage(&content_storage, storage_id)); - R_ASSERT(content_storage->GetPath(out.GetPointer(), data_content_id)); + R_ABORT_UNLESS(content_storage->GetPath(out.GetPointer(), data_content_id)); return ResultSuccess(); } diff --git a/stratosphere/ncm/source/lr_contentlocationresolver.cpp b/stratosphere/ncm/source/lr_contentlocationresolver.cpp index 1e5df72cf..dcf074a16 100644 --- a/stratosphere/ncm/source/lr_contentlocationresolver.cpp +++ b/stratosphere/ncm/source/lr_contentlocationresolver.cpp @@ -24,7 +24,7 @@ namespace ams::lr { } void ContentLocationResolverInterface::GetContentStoragePath(Path* out, ncm::ContentId content_id) { - R_ASSERT(this->content_storage->GetPath(out, content_id)); + R_ABORT_UNLESS(this->content_storage->GetPath(out, content_id)); } Result ContentLocationResolverInterface::ResolveProgramPath(sf::Out out, ncm::ProgramId id) { diff --git a/stratosphere/ncm/source/ncm_contentstorage.cpp b/stratosphere/ncm/source/ncm_contentstorage.cpp index 89112635d..37b10f236 100644 --- a/stratosphere/ncm/source/ncm_contentstorage.cpp +++ b/stratosphere/ncm/source/ncm_contentstorage.cpp @@ -89,7 +89,7 @@ namespace ams::ncm { Result ContentStorageInterface::GeneratePlaceHolderId(sf::Out out) { R_TRY(this->EnsureEnabled()); - ams::rnd::GenerateRandomBytes(out.GetPointer(), sizeof(PlaceHolderId)); + ams::os::GenerateRandomBytes(out.GetPointer(), sizeof(PlaceHolderId)); char placeholder_str[FS_MAX_PATH] = {0}; GetStringFromPlaceHolderId(placeholder_str, *out.GetPointer()); return ResultSuccess(); diff --git a/stratosphere/ncm/source/ncm_main.cpp b/stratosphere/ncm/source/ncm_main.cpp index 7d92c35f5..caa4c7cfb 100644 --- a/stratosphere/ncm/source/ncm_main.cpp +++ b/stratosphere/ncm/source/ncm_main.cpp @@ -73,7 +73,7 @@ void __appInit(void) { hos::SetVersionForLibnx(); sm::DoWithSession([&]() { - R_ASSERT(fsInitialize()); + R_ABORT_UNLESS(fsInitialize()); }); ams::CheckApiVersion(); @@ -107,7 +107,7 @@ namespace { void ContentManagerServerMain(void* arg) { /* Create services. */ - R_ASSERT(g_ncm_server_manager.RegisterServer(NcmServiceName, NcmMaxSessions)); + R_ABORT_UNLESS(g_ncm_server_manager.RegisterServer(NcmServiceName, NcmMaxSessions)); /* Loop forever, servicing our services. */ g_ncm_server_manager.LoopProcess(); @@ -115,7 +115,7 @@ void ContentManagerServerMain(void* arg) { void LocationResolverServerMain(void* arg) { /* Create services. */ - R_ASSERT(g_lr_server_manager.RegisterServer(LrServiceName, LrMaxSessions)); + R_ABORT_UNLESS(g_lr_server_manager.RegisterServer(LrServiceName, LrMaxSessions)); /* Loop forever, servicing our services. */ g_lr_server_manager.LoopProcess(); @@ -124,16 +124,16 @@ void LocationResolverServerMain(void* arg) { int main(int argc, char **argv) { /* Initialize content manager implementation. */ - R_ASSERT(ams::ncm::impl::InitializeContentManager()); + R_ABORT_UNLESS(ams::ncm::impl::InitializeContentManager()); static os::Thread s_content_manager_thread; static os::Thread s_location_resolver_thread; - R_ASSERT(s_content_manager_thread.Initialize(&ContentManagerServerMain, nullptr, 0x4000, 0x15)); - R_ASSERT(s_content_manager_thread.Start()); + R_ABORT_UNLESS(s_content_manager_thread.Initialize(&ContentManagerServerMain, nullptr, 0x4000, 0x15)); + R_ABORT_UNLESS(s_content_manager_thread.Start()); - R_ASSERT(s_location_resolver_thread.Initialize(&LocationResolverServerMain, nullptr, 0x4000, 0x15)); - R_ASSERT(s_location_resolver_thread.Start()); + R_ABORT_UNLESS(s_location_resolver_thread.Initialize(&LocationResolverServerMain, nullptr, 0x4000, 0x15)); + R_ABORT_UNLESS(s_location_resolver_thread.Start()); s_content_manager_thread.Join(); s_location_resolver_thread.Join();