diff --git a/inc/thorvg.h b/inc/thorvg.h index 3a53d0a3..1ee76984 100644 --- a/inc/thorvg.h +++ b/inc/thorvg.h @@ -1272,7 +1272,7 @@ public: * @param[in] threads The number of additional threads. Zero indicates only the main thread is to be used. * * @retval Result::Success When succeed. - * @retval Result::InsufficientCondition An internal error possibly with memory allocation. + * @retval Result::FailedAllocation An internal error possibly with memory allocation. * @retval Result::InvalidArguments If unknown engine type chosen. * @retval Result::NonSupport In case the engine type is not supported on the system. * @retval Result::Unknown Others. diff --git a/src/lib/tvgInitializer.cpp b/src/lib/tvgInitializer.cpp index ca952c47..c36b02f3 100644 --- a/src/lib/tvgInitializer.cpp +++ b/src/lib/tvgInitializer.cpp @@ -49,12 +49,12 @@ Result Initializer::init(CanvasEngine engine, uint32_t threads) noexcept if (static_cast(engine) & static_cast(CanvasEngine::Sw)) { #ifdef THORVG_SW_RASTER_SUPPORT - if (!SwRenderer::init(threads)) return Result::InsufficientCondition; + if (!SwRenderer::init(threads)) return Result::FailedAllocation; nonSupport = false; #endif } else if (static_cast(engine) & static_cast(CanvasEngine::Gl)) { #ifdef THORVG_GL_RASTER_SUPPORT - if (!GlRenderer::init(threads)) return Result::InsufficientCondition; + if (!GlRenderer::init(threads)) return Result::FailedAllocation; nonSupport = false; #endif } else {