aboutsummaryrefslogtreecommitdiffstats
path: root/src/lua
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@rspamd.com>2023-09-08 15:14:32 +0100
committerVsevolod Stakhov <vsevolod@rspamd.com>2023-09-08 15:16:32 +0100
commit0835db27a1bd8b61e9ca2fda14072e6f924e248f (patch)
treed644e2647f439bcc426e663722ef3db6a709fabd /src/lua
parent558e1039418c192f281cbde65f51d21b0ed51a73 (diff)
downloadrspamd-0835db27a1bd8b61e9ca2fda14072e6f924e248f.tar.gz
rspamd-0835db27a1bd8b61e9ca2fda14072e6f924e248f.zip
[Minor] Fix some warnings
Diffstat (limited to 'src/lua')
-rw-r--r--src/lua/lua_kann.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/lua/lua_kann.c b/src/lua/lua_kann.c
index ace47dd70..e42fbfbc5 100644
--- a/src/lua/lua_kann.c
+++ b/src/lua/lua_kann.c
@@ -1,11 +1,11 @@
-/*-
- * Copyright 2019 Vsevolod Stakhov
+/*
+ * Copyright 2023 Vsevolod Stakhov
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
@@ -824,7 +824,7 @@ lua_kann_new_leaf(lua_State *L)
kad_node_t *t;
if (dim >= 1 && dim < KAD_MAX_DIM && lua_istable(L, 2)) {
- ar = g_new0(int, dim);
+ ar = g_new0(int, KAD_MAX_DIM);
for (i = 0; i < dim; i++) {
lua_rawgeti(L, 2, i + 1);