]> source.dussan.org Git - rspamd.git/commitdiff
[Minor] Allow nil options when adding symbols
authorVsevolod Stakhov <vsevolod@highsecure.ru>
Mon, 9 Dec 2019 12:32:58 +0000 (12:32 +0000)
committerVsevolod Stakhov <vsevolod@highsecure.ru>
Mon, 9 Dec 2019 12:32:58 +0000 (12:32 +0000)
src/lua/lua_task.c

index 7072ebe35ed62abc43cc84105142a9bc8e131904..cf57ebf131a8c743dd9cac861f716c657ba3a8c0 100644 (file)
@@ -1896,6 +1896,12 @@ lua_task_insert_result (lua_State * L)
 
                                        lua_pop (L, 1);
                                }
+                               else if (ltype == LUA_TNIL) {
+                                       /* We have received a NULL option, it is not good but not a fatal error */
+                                       msg_info_task ("nil option when adding symbol %s at pos %d",
+                                                       s->name, i);
+                                       continue;
+                               }
                                else {
                                        const gchar *tname = lua_typename (L, ltype);