lua: fix interpreter used in API functions (bug #39470)
core: fix malloc(0) when building content of a bar using a filling with columns