From 872d588c51d8cf56d4452c40057c7571c3c252bf Mon Sep 17 00:00:00 2001 From: twinaphex Date: Wed, 1 Jul 2015 19:42:36 +0200 Subject: [PATCH] (msg_hash_to_str) if settings is NULL, default to english strings --- msg_hash.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/msg_hash.c b/msg_hash.c index 7ceed3a28b..ead19f9634 100644 --- a/msg_hash.c +++ b/msg_hash.c @@ -26,7 +26,7 @@ const char *msg_hash_to_str(uint32_t hash) settings_t *settings = config_get_ptr(); if (!settings) - return "null"; + goto end; switch (settings->user_language) { @@ -57,6 +57,7 @@ const char *msg_hash_to_str(uint32_t hash) if (ret && strcmp(ret, "null") != 0) return ret; +end: return msg_hash_to_str_us(hash); }