summaryrefslogtreecommitdiff
path: root/lib/frrscript.h
diff options
context:
space:
mode:
authorDonald Lee <dlqs@gmx.com>2021-07-17 20:46:10 +0800
committerDonald Lee <dlqs@gmx.com>2021-07-18 06:32:03 +0800
commit2b67227e6e69a0d5ce1831185f95182f8874ee37 (patch)
tree0656b47a3192065d62d8ccae37bf9a381c7fe8b6 /lib/frrscript.h
parent8878080b1b5185c45ce1ec6f633d628ca41643ad (diff)
lib: Add int encoder/decoder
Signed-off-by: Donald Lee <dlqs@gmx.com>
Diffstat (limited to 'lib/frrscript.h')
-rw-r--r--lib/frrscript.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/frrscript.h b/lib/frrscript.h
index 905cda1a95..be6820bed5 100644
--- a/lib/frrscript.h
+++ b/lib/frrscript.h
@@ -142,6 +142,7 @@ void frrscript_init(const char *scriptdir);
*/
#define ENCODE_ARGS_WITH_STATE(L, value) \
_Generic((value), \
+int: lua_pushinteger, \
long long * : lua_pushintegerp, \
struct prefix * : lua_pushprefix, \
struct interface * : lua_pushinterface, \
@@ -157,6 +158,7 @@ const struct prefix * : lua_pushprefix \
#define DECODE_ARGS_WITH_STATE(L, value) \
_Generic((value), \
+int : lua_decode_int_noop, \
long long * : lua_decode_integerp, \
struct prefix * : lua_decode_prefix, \
struct interface * : lua_decode_interface, \