diff options
author | Antonio Borneo <borneo.antonio@gmail.com> | 2020-05-13 15:35:19 +0200 |
---|---|---|
committer | Antonio Borneo <borneo.antonio@gmail.com> | 2021-04-18 15:34:43 +0100 |
commit | a7d68878e4ba5dfd5ca15c058980cf6c5fc55208 (patch) | |
tree | 8932ed57728608b61f807bc7c5538126c7b5e1ed /src/helper/command.h | |
parent | d8d24f3b3696f5d2e64a67df87684132b48031d2 (diff) | |
download | riscv-openocd-a7d68878e4ba5dfd5ca15c058980cf6c5fc55208.zip riscv-openocd-a7d68878e4ba5dfd5ca15c058980cf6c5fc55208.tar.gz riscv-openocd-a7d68878e4ba5dfd5ca15c058980cf6c5fc55208.tar.bz2 |
helper/command: unregister commands through their full-name
While keeping the struct command in place, unregister the jim
commands by scanning the list of jim commands through their
full-name.
Change-Id: I0e903fbc31172858b703d67ccd471809c7949e86
Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
Reviewed-on: http://openocd.zylin.com/5674
Tested-by: jenkins
Reviewed-by: Oleksij Rempel <linux@rempel-privat.de>
Diffstat (limited to 'src/helper/command.h')
-rw-r--r-- | src/helper/command.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/helper/command.h b/src/helper/command.h index db09597..4d1928c 100644 --- a/src/helper/command.h +++ b/src/helper/command.h @@ -311,11 +311,11 @@ static inline int register_commands_with_data(struct command_context *cmd_ctx, /** * Unregisters all commands from the specified context. * @param cmd_ctx The context that will be cleared of registered commands. - * @param parent If given, only clear commands from under this one command. + * @param cmd_prefix If given, only clear commands from under this one command. * @returns ERROR_OK on success, or an error code. */ int unregister_all_commands(struct command_context *cmd_ctx, - struct command *parent); + const char *cmd_prefix); /** * Unregisters the help for all commands. Used at exit to remove the help |