From 04c5f0268227d000c094c411c9ce2346cb671d81 Mon Sep 17 00:00:00 2001 From: Maschell Date: Fri, 17 Feb 2023 13:22:19 +0100 Subject: [PATCH] Use make_unique_nothrow instead of std::make_unique --- source/PluginUtils.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/source/PluginUtils.cpp b/source/PluginUtils.cpp index 96974f7..dd5a480 100644 --- a/source/PluginUtils.cpp +++ b/source/PluginUtils.cpp @@ -124,7 +124,7 @@ std::optional> PluginUtils::getPluginForBuffer( std::vector> PluginUtils::getLoadedPlugins(uint32_t maxSize) { std::vector> result; - auto handles = std::make_unique(maxSize); + auto handles = make_unique_nothrow(maxSize); if (!handles) { DEBUG_FUNCTION_LINE_ERR("Not enough memory"); return result; @@ -146,7 +146,7 @@ std::vector> PluginUtils::getLoadedPlugins(uint return result; } - auto dataHandles = std::make_unique(realSize); + auto dataHandles = make_unique_nothrow(realSize); if (!dataHandles) { DEBUG_FUNCTION_LINE_ERR("Not enough memory"); return result; @@ -157,7 +157,7 @@ std::vector> PluginUtils::getLoadedPlugins(uint return result; } - auto information = std::make_unique(realSize); + auto information = make_unique_nothrow(realSize); if (!information) { DEBUG_FUNCTION_LINE_ERR("Not enough memory"); return result;