diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2019-07-03 12:37:36 +0100 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2019-07-03 12:37:36 +0100 |
commit | 242269c12afc214da1c75954a3f5b167d2faba40 (patch) | |
tree | bc9c3b74c1bddcc7cd63298b61f8afa767099412 /src/lua/lua_kann.c | |
parent | 55f59de699aa0c7c7018e05375131d22cfd46530 (diff) | |
download | rspamd-242269c12afc214da1c75954a3f5b167d2faba40.tar.gz rspamd-242269c12afc214da1c75954a3f5b167d2faba40.zip |
[Minor] Zero pointer to avoid free issues
Diffstat (limited to 'src/lua/lua_kann.c')
-rw-r--r-- | src/lua/lua_kann.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/lua/lua_kann.c b/src/lua/lua_kann.c index 609f05539..e356f5912 100644 --- a/src/lua/lua_kann.c +++ b/src/lua/lua_kann.c @@ -1067,8 +1067,8 @@ lua_kann_train1 (lua_State *L) float **x, **y; /* Fill vectors */ - x = (float **)g_malloc (sizeof (float *) * n); - y = (float **)g_malloc (sizeof (float *) * n); + x = (float **)g_malloc0 (sizeof (float *) * n); + y = (float **)g_malloc0 (sizeof (float *) * n); for (int s = 0; s < n; s ++) { /* Inputs */ |