diff options
author | Ondrej Zajicek (work) <santiago@crfreenet.org> | 2019-07-24 15:38:32 +0200 |
---|---|---|
committer | Ondrej Zajicek (work) <santiago@crfreenet.org> | 2019-07-24 15:38:32 +0200 |
commit | cec40a74679821513e627f93b924067a404f6475 (patch) | |
tree | 793bbe5b326e7008e4657cf11b2937cafbe3d922 /nest/cmds.c | |
parent | 18f70a6229f586d5e4f387075be42d7a1ef5d269 (diff) | |
parent | 8263690e754a83b8f3c58bd0080a1628d6cba556 (diff) |
Merge remote-tracking branch 'origin/mq-filter-stack'
Diffstat (limited to 'nest/cmds.c')
-rw-r--r-- | nest/cmds.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/nest/cmds.c b/nest/cmds.c index ca601ef2..da4015cf 100644 --- a/nest/cmds.c +++ b/nest/cmds.c @@ -95,18 +95,16 @@ cmd_show_memory(void) } void -cmd_eval(struct f_inst *expr) +cmd_eval(const struct f_line *expr) { - struct f_val v = f_eval(expr, this_cli->parser_pool); + buffer buf; + LOG_BUFFER_INIT(buf); - if (v.type == T_RETURN) + if (f_eval_buf(expr, this_cli->parser_pool, &buf) > F_RETURN) { cli_msg(8008, "runtime error"); return; } - buffer buf; - LOG_BUFFER_INIT(buf); - val_format(v, &buf); cli_msg(23, "%s", buf.start); } |