[Rpm-maint] [rpm-software-management/rpm] [regression?] arg[2] to lua scriptlet became a string instead of number (#1790)

Michael Schroeder notifications at github.com
Mon Nov 15 09:26:58 UTC 2021


If you can live with a hack, add something like this to runLuaScript (totally untested):
```
    if (arg1 >= 0 || arg2 >= 0) {
        if (arg1 >= 0 && arg2 >= 0)
            scriptbuf = xstrdup("arg[#arg-1] = tonumber(arg[#arg-1]);");
        rstrscat(&scriptbuf, "arg[#arg] = tonumber(arg[#arg]);", script, NULL);
        script = scriptbuf;
    }
```

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/issues/1790#issuecomment-968695608
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rpm.org/pipermail/rpm-maint/attachments/20211115/0a2d2ee0/attachment.html>


More information about the Rpm-maint mailing list