From a488034065baa435376f4f8e2cce526d964577fc Mon Sep 17 00:00:00 2001 From: Magnus Norddahl Date: Mon, 8 Apr 2019 04:57:46 +0200 Subject: [PATCH] - fix null pointer crash --- src/rendering/hwrenderer/postprocessing/hw_postprocess.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/rendering/hwrenderer/postprocessing/hw_postprocess.cpp b/src/rendering/hwrenderer/postprocessing/hw_postprocess.cpp index 99e9b509a..0e7880806 100644 --- a/src/rendering/hwrenderer/postprocessing/hw_postprocess.cpp +++ b/src/rendering/hwrenderer/postprocessing/hw_postprocess.cpp @@ -1001,8 +1001,9 @@ void PPCustomShaderInstance::AddUniformField(size_t &offset, const FString &name FieldOffset[name] = offset; auto name2 = std::make_unique(name); + auto chars = name2->GetChars(); FieldNames.push_back(std::move(name2)); - Fields.push_back({ name2->GetChars(), type, offset }); + Fields.push_back({ chars, type, offset }); offset += fieldsize; }