diff options
Diffstat (limited to 'lib/frrscript.c')
| -rw-r--r-- | lib/frrscript.c | 18 |
1 files changed, 1 insertions, 17 deletions
diff --git a/lib/frrscript.c b/lib/frrscript.c index 10d400886d..1a9f3639dd 100644 --- a/lib/frrscript.c +++ b/lib/frrscript.c @@ -104,24 +104,8 @@ static void codec_free(struct codec *c) /* Generic script APIs */ -int frrscript_call(struct frrscript *fs, struct frrscript_env *env) +int _frrscript_call(struct frrscript *fs) { - struct frrscript_codec c = {}; - const void *arg; - const char *bindname; - - /* Encode script arguments */ - for (int i = 0; env && env[i].val != NULL; i++) { - bindname = env[i].name; - c.typename = env[i].typename; - arg = env[i].val; - - struct frrscript_codec *codec = hash_lookup(codec_hash, &c); - assert(codec && "No encoder for type"); - codec->encoder(fs->L, arg); - - lua_setglobal(fs->L, bindname); - } int ret = lua_pcall(fs->L, 0, 0, 0); |
