From e19b4cebd67b7b6a6963ce320a00546697e2a01c Mon Sep 17 00:00:00 2001 From: Roman Fomin Date: Thu, 16 Jan 2025 23:46:18 +0700 Subject: [PATCH] add check for parse error in TRAKINFO --- src/s_trakinfo.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/s_trakinfo.c b/src/s_trakinfo.c index 903b81ecb..bb9c14b95 100644 --- a/src/s_trakinfo.c +++ b/src/s_trakinfo.c @@ -36,6 +36,10 @@ static trakinfo_t *trakinfo; void S_ParseTrakInfo(int lumpnum) { json_t *json = JS_OpenOptions(lumpnum, true); + if (!json) + { + return; + } json_obj_iter_t *iter = JS_ObjectIterator(json);