]> git.puffer.fish Git - matthieu/frr.git/commitdiff
tests/testcli: cleanup at exit
authorDavid Lamparter <equinox@opensourcerouting.org>
Thu, 26 Jan 2017 20:57:58 +0000 (21:57 +0100)
committerDavid Lamparter <equinox@opensourcerouting.org>
Tue, 31 Jan 2017 14:28:39 +0000 (15:28 +0100)
Call the proper termination functions so we can see memory leaks.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
tests/common-cli.c

index 7f7d253e6cc9e9eddad88a26f7e7e1859d4fce4f..47476711c69676a34f8a9f429e72bd35cf798eb4 100644 (file)
@@ -49,6 +49,12 @@ int dump_args(struct vty *vty, const char *descr,
 static void vty_do_exit(void)
 {
   printf ("\nend.\n");
+  cmd_terminate ();
+  vty_terminate ();
+  thread_master_free (master);
+  closezlog (zlog_default);
+
+  log_memstats_stderr ("testcli");
   exit (0);
 }