aboutsummaryrefslogtreecommitdiffstats
path: root/src/vty/talloc_ctx_vty.c
AgeCommit message (Collapse)AuthorFilesLines
2019-04-11vty/talloc_ctx_vty.c: use REG_NOSUB flag of regcomp()Vadim Yanitskiy1-1/+1
We don't need to know position of matches: just yes or no. This change would save some computation power. Change-Id: Id55ffe64cc1a35dd83f61dbb0f9828aa676696f9
2019-04-11vty/talloc_ctx_vty.c: allocate walk_cb_params on stack, not heapVadim Yanitskiy1-43/+15
There is no need to allocate struct 'walk_cb_params' dynamically. Change-Id: I96f25f1ddb36b19b12055deaeeb6f58e59180e72
2018-02-14talloc_ctx_vty: Fix help strings (missing \n at end of line)Harald Welte1-3/+3
This was causing build failures in applications using this library feature: Documentation error (missing docs): <command id='show talloc-context (application|all) (full|brief|DEPTH) tree ADDRESS'> <param name='ADDRESS' doc='(null)' /> Documentation error (missing docs): <command id='show talloc-context (application|all) (full|brief|DEPTH) filter REGEXP'> <param name='REGEXP' doc='(null)' /> Documentation error (missing docs): <command id='show talloc-context (application|all) (full|brief|DEPTH) tree ADDRESS'> <param name='ADDRESS' doc='(null)' /> Documentation error (missing docs): <command id='show talloc-context (application|all) (full|brief|DEPTH) filter REGEXP'> <param name='REGEXP' doc='(null)' /> Change-Id: I785c852e3313d20eade79746a7cd485d2d5908ea
2017-11-13Fix/Update copyright notices; Add SPDX annotationHarald Welte1-0/+2
Let's fix some erroneous/accidential references to wrong license, update copyright information where applicable and introduce a SPDX-License-Identifier to all files. Change-Id: I39af26c6aaaf5c926966391f6565fc5936be21af
2017-09-27VTY: implement talloc context introspection commandVadim Yanitskiy1-0/+279
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