summaryrefslogtreecommitdiff
path: root/nest/cli.h
diff options
context:
space:
mode:
authorMaria Matejka <mq@ucw.cz>2022-09-29 09:58:27 +0200
committerMaria Matejka <mq@ucw.cz>2022-09-29 09:59:32 +0200
commit61c127c021ac34eba25d3245ccf8f9eb9dd352f5 (patch)
tree92108ea957c157ea1f8cbc8089cebb953dcad6d4 /nest/cli.h
parent9be7aa9b450f22cec9c97143d0cb7650f4fd7cc9 (diff)
parent9efaf6bafea1c69629e59c6504980fb2986287fe (diff)
Merge commit '9efaf6ba' into tmp-bad-learn
Also fixed forgotten best route selection among alien routes.
Diffstat (limited to 'nest/cli.h')
-rw-r--r--nest/cli.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/nest/cli.h b/nest/cli.h
index 8a3294c5..92572968 100644
--- a/nest/cli.h
+++ b/nest/cli.h
@@ -33,12 +33,12 @@ typedef struct cli {
struct cli_out *tx_buf, *tx_pos, *tx_write;
event *event;
void (*cont)(struct cli *c);
- void (*cleanup)(struct cli *c);
+ int (*cleanup)(struct cli *c); /* Return 0 if finished and cli may be freed immediately.
+ Otherwise return 1 and call rfree(c->pool) when appropriate. */
void *rover; /* Private to continuation routine */
int last_reply;
int restricted; /* CLI is restricted to read-only commands */
struct linpool *parser_pool; /* Pool used during parsing */
- struct linpool *show_pool; /* Pool used during route show */
byte *ring_buf; /* Ring buffer for asynchronous messages */
byte *ring_end, *ring_read, *ring_write; /* Pointers to the ring buffer */
uint ring_overflow; /* Counter of ring overflows */