summaryrefslogtreecommitdiff
path: root/source3/web/neg_lang.c
diff options
context:
space:
mode:
Diffstat (limited to 'source3/web/neg_lang.c')
-rw-r--r--source3/web/neg_lang.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/source3/web/neg_lang.c b/source3/web/neg_lang.c
index ca671822d8..fb79f41f13 100644
--- a/source3/web/neg_lang.c
+++ b/source3/web/neg_lang.c
@@ -86,6 +86,10 @@ void web_set_lang(const char *lang_string)
lang_num++;
}
pl = SMB_MALLOC_ARRAY(struct pri_list, lang_num);
+ if (!pl) {
+ return;
+ }
+
for (i = 0; i < lang_num; i++) {
char *pri_code;
if ((pri_code=strstr(lang_list[i], ";q="))) {