diff options
| author | Donald Lee <dlqs@gmx.com> | 2021-07-08 01:32:30 +0800 |
|---|---|---|
| committer | Donald Lee <dlqs@gmx.com> | 2021-07-18 06:32:03 +0800 |
| commit | ad6e9b854d64aa91eef2d965b7778188d2d7811a (patch) | |
| tree | 9a78be8f3922bad4a047808c9fa91b3b1ecc7a68 | |
| parent | fae19fa56d110b27bc4f507221573b432cdfc9a8 (diff) | |
test: Use frrscript_unload
Signed-off-by: Donald Lee <dlqs@gmx.com>
| -rw-r--r-- | lib/command.c | 2 | ||||
| -rw-r--r-- | tests/lib/test_frrscript.c | 2 |
2 files changed, 4 insertions, 0 deletions
diff --git a/lib/command.c b/lib/command.c index b2b80daddd..7808f57594 100644 --- a/lib/command.c +++ b/lib/command.c @@ -2443,6 +2443,8 @@ DEFUN(script, vty_out(vty, "p: %s\n", buf); vty_out(vty, "Script result: %d\n", ret); + frrscript_unload(fs); + return CMD_SUCCESS; } #endif diff --git a/tests/lib/test_frrscript.c b/tests/lib/test_frrscript.c index e8b7927e15..399b950799 100644 --- a/tests/lib/test_frrscript.c +++ b/tests/lib/test_frrscript.c @@ -72,5 +72,7 @@ int main(int argc, char **argv) result = frrscript_call(fs, "bad_return3"); assert(result == 1); + frrscript_unload(fs); + return 0; } |
