libosmocore/src/vty
Vadim Yanitskiy 463deef8c2 VTY: implement talloc context introspection command
This change introduces a new command, which could be used to
inspect the application's talloc context directly from VTY.
To enable this feature, an application need to provide it's
context via the 'vty_app_info' struct, and register the VTY
command by calling the osmo_talloc_vty_add_cmds().

The new command is a sub-command of 'show':

  show talloc-context <context> <depth> [filter]

Currently the following contexts may be inspected:

  - application - a context provided by an application;
  - null - all contexts, if NULL-context tracking is enabled.

A report depth is defined by the next parameter, and could be:

  - full - full tree report, as the talloc_report_full() does;
  - brief - brief tree report, as the talloc_report() does;
  - DEPTH - user defined maximal report depth.

Also, there are two optional report filters:

  - regexp - print only contexts, matching a regular expression;
  - tree - print a specific context, pointed by specified address.

The command output is formatted the same way as in case of calling
the talloc_report() or talloc_report_full().

Change-Id: I43fc42880b22294d83c565ae600ac65e4f38b30d
2017-09-27 11:02:19 +00:00
..
Makefile.am VTY: implement talloc context introspection command 2017-09-27 11:02:19 +00:00
buffer.c doxygen: unify use of \file across the board 2017-06-23 00:18:23 +00:00
command.c vty: derive node name from prompt, use as XML ids 2017-09-23 12:24:58 +00:00
fsm_vty.c doxygen: unify use of \file across the board 2017-06-23 00:18:23 +00:00
logging_vty.c Ignore broken everything log level 2017-07-10 11:33:14 +02:00
stats_vty.c doxygen: unify use of \file across the board 2017-06-23 00:18:23 +00:00
talloc_ctx_vty.c VTY: implement talloc context introspection command 2017-09-27 11:02:19 +00:00
telnet_interface.c doxygen: unify use of \file across the board 2017-06-23 00:18:23 +00:00
utils.c doxygen: unify use of \file across the board 2017-06-23 00:18:23 +00:00
vector.c doxygen: unify use of \file across the board 2017-06-23 00:18:23 +00:00
vty.c vty/vty.c: do not bind vty context to application's one 2017-09-27 11:02:18 +00:00