]> git.ipfire.org Git - thirdparty/rspamd.git/commit
fix(lua-lupa): Use local loop variable 6130/head
authorEthan D. Twardy <ethan.twardy@gmail.com>
Fri, 10 Jul 2026 23:03:58 +0000 (18:03 -0500)
committerEthan D. Twardy <ethan.twardy@gmail.com>
Fri, 10 Jul 2026 23:13:07 +0000 (18:13 -0500)
commit386ed6ed1c986568fee9b765d35cc328c8c5966e
treed23acc9548d86ae7c0f6d72d05dbfa5b645c1ff6
parent79bfda9b289d987e43610630661383b49f88636b
fix(lua-lupa): Use local loop variable

Lua 5.5 makes `for` expression variables constant. The recent upgrade to
lua 5.5 broke lua-lupa, which previously attempted to modify the loop
variable. This caused an unrecoverable error on startup:

rspamd_lua_require_function: require of lua_util.jinja_template failed: error loading module 'lupa' from file '/usr/share/rspamd/lualib/lupa.lua':\x0A\x09/usr/share/rspamd/lualib/lupa.lua:1858: attempt to assign to const variable 'word'
contrib/lua-lupa/lupa.lua