diff options
| author | Donald Lee <dlqs@gmx.com> | 2021-08-10 04:41:25 +0800 |
|---|---|---|
| committer | Quentin Young <qlyoung@qlyoung.net> | 2023-11-20 20:45:02 -0500 |
| commit | d2acf63f16837caaadd093927c236b742c19fd75 (patch) | |
| tree | 9a6b11c90de0c01a40ceb8e8d5fa60afb22bbb3e /lib/frrscript.h | |
| parent | ac91b343d635f056e8de47224719ed6218e79dfb (diff) | |
lib: Create encoders for int and rename stuff
Create encoders/decoders for int and rename current int encoders
/decoders to long long.
Signed-off-by: Donald Lee <dlqs@gmx.com>
Diffstat (limited to 'lib/frrscript.h')
| -rw-r--r-- | lib/frrscript.h | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/lib/frrscript.h b/lib/frrscript.h index f842dd9f45..ce313a1b63 100644 --- a/lib/frrscript.h +++ b/lib/frrscript.h @@ -197,8 +197,9 @@ void _lua_decode_noop(lua_State *, ...); #define ENCODE_ARGS_WITH_STATE(L, value) \ _Generic((value), \ int : lua_pushinteger, \ +int * : lua_pushintegerp, \ long long : lua_pushinteger, \ -long long * : lua_pushintegerp, \ +long long * : lua_pushlonglongp, \ struct prefix * : lua_pushprefix, \ struct interface * : lua_pushinterface, \ struct in_addr * : lua_pushinaddr, \ @@ -217,8 +218,8 @@ struct zebra_dplane_ctx * : lua_pushzebra_dplane_ctx \ #define DECODE_ARGS_WITH_STATE(L, value) \ _Generic((value), \ -int : lua_decode_integer_noop, \ -long long * : lua_decode_integerp, \ +int * : lua_decode_integerp, \ +long long * : lua_decode_longlongp, \ struct prefix * : lua_decode_prefix, \ struct interface * : lua_decode_interface, \ struct in_addr * : lua_decode_inaddr, \ |
