diff options
| author | Quentin Young <qlyoung@cumulusnetworks.com> | 2018-06-06 19:09:44 +0000 |
|---|---|---|
| committer | Quentin Young <qlyoung@cumulusnetworks.com> | 2018-06-06 19:09:44 +0000 |
| commit | 0b42d81ab8b4bd15791ba3e72bc26f41827576a7 (patch) | |
| tree | 8da4e9a2ef88420356cc021f7e7a5c30cb6be9d1 /lib/command.c | |
| parent | 6ef6e4f0531f34cd5f7930483ed50231fdf6af3a (diff) | |
lib: fix output mangling with | include
Sometimes output would be mangled when filtering with include as a
result of the following bugs:
* Filters were applied per each call to vty_out() instead of buffering
until a line break and then applying
* Long output would sometimes be cut due to using the wrong buffer
pointer
Also remove the trailing \n as it should no longer be necessary to
ensure the vty prompt ends up on a new line.
Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
Diffstat (limited to 'lib/command.c')
| -rw-r--r-- | lib/command.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/lib/command.c b/lib/command.c index b7690eac4c..7df81438f2 100644 --- a/lib/command.c +++ b/lib/command.c @@ -1226,10 +1226,9 @@ fail: static int handle_pipe_action_done(struct vty *vty, const char *cmd_exec) { - if (vty->filter) { + if (vty->filter) vty_set_include(vty, NULL); - vty_out(vty, "\n"); - } + return 0; } |
