lua: fix some nasty memory leaks

2 jobs for lua-monitors in 1 minute and 13 seconds (queued for 1 second)
Status Job ID Name Coverage
  Container
passed container_fedora #6777275

00:00:15

 
  Build
passed build_on_fedora #6777276

00:00:58