From e1c3e96eb15849c902a14150808f0629c9e05be1 Mon Sep 17 00:00:00 2001 From: jaynus Date: Fri, 15 May 2015 10:45:07 -0700 Subject: [PATCH] Fixes: Nil scheduled space bug with hashes. This is still a bug everywhere else. --- addons/common/functions/fnc_hashGet.sqf | 4 +++- addons/common/functions/fnc_hashListSelect.sqf | 2 ++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/addons/common/functions/fnc_hashGet.sqf b/addons/common/functions/fnc_hashGet.sqf index ea2e104de5..dfcf84e443 100644 --- a/addons/common/functions/fnc_hashGet.sqf +++ b/addons/common/functions/fnc_hashGet.sqf @@ -23,4 +23,6 @@ try { } catch { HANDLECATCH; }; -_val + +if (isNil "_val") exitWith { nil }; +_val; diff --git a/addons/common/functions/fnc_hashListSelect.sqf b/addons/common/functions/fnc_hashListSelect.sqf index df91f3ac77..195e508244 100644 --- a/addons/common/functions/fnc_hashListSelect.sqf +++ b/addons/common/functions/fnc_hashListSelect.sqf @@ -23,4 +23,6 @@ try { } catch { HANDLECATCH; }; + +if (isNil "_hash") exithWith { nil }; _hash;