From 1e41c042d4d1482579b0a34c6791cde646e97c39 Mon Sep 17 00:00:00 2001 From: "alexey.lysiuk" Date: Mon, 19 Feb 2018 11:46:36 +0200 Subject: [PATCH] Fixed codegen crash with non-numeric random seed The following code crashed ZScript code generator if my_seed is not convertible to numeric type SetRandomSeed[my_random_id](my_seed); --- src/scripting/backend/codegen.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/scripting/backend/codegen.cpp b/src/scripting/backend/codegen.cpp index a9c7e4fcc..96393ad4c 100644 --- a/src/scripting/backend/codegen.cpp +++ b/src/scripting/backend/codegen.cpp @@ -5945,7 +5945,7 @@ FxRandomSeed::~FxRandomSeed() FxExpression *FxRandomSeed::Resolve(FCompileContext &ctx) { CHECKRESOLVED(); - RESOLVE(seed, ctx); + SAFE_RESOLVE(seed, ctx); return this; };