openocd/src/helper
Antonio Borneo f912649968 helper/command: remove dead code in command_unknown()
Commit 89fa493a3b removes the top
level command "unknown" and adds in command_unknown() some unclear
code that should detect a user-implemented "unknown" command.
But, all the commands that trigger the execution of the function
command_unknown() are registered in register_command_handler() and
have the command name prefixed with "ocd_".
Due to such "ocd_" prefix in cmd_name, the condition
	if (strcmp(cmd_name, "unknown") == 0) { ... }
is always false.
Nobody complained for almost 10 years so we can proceed to remove
this dead code, before merging any change that obsoletes the
prefix "ocd_" and potentially makes the condition true.

Remove the dead code guarded by the condition above.

Change-Id: Icf11a956bb2d68fc84e6eb5779edf8e35db8fa53
Fixes: 89fa493a3b ("remove unknown handler")
Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
Reviewed-on: http://openocd.zylin.com/5096
Tested-by: jenkins
Reviewed-by: Tomas Vanek <vanekt@fbl.cz>
2019-05-23 22:13:09 +01:00
..
Makefile.am helper,rtos,server: Restore missing warning flags 2017-01-15 10:16:16 +00:00
bin2char.sh Fix some problems with the bin2char utility 2014-08-02 09:01:32 +00:00
binarybuffer.c helper: Code cleanup for hexify() 2016-12-08 12:34:53 +00:00
binarybuffer.h fix for sanitizer errors in left shifts 2019-04-10 16:37:51 +01:00
command.c helper/command: remove dead code in command_unknown() 2019-05-23 22:13:09 +01:00
command.h helper/command: Handle Tcl return values consistently 2019-05-14 19:38:22 +01:00
configuration.c helper/configuration: free script_search_dirs and config_file_names 2018-03-07 23:47:31 +00:00
configuration.h helper/configuration: free script_search_dirs and config_file_names 2018-03-07 23:47:31 +00:00
fileio.c Handle improperly build image files gracefully 2018-02-14 08:27:01 +00:00
fileio.h Handle improperly build image files gracefully 2018-02-14 08:27:01 +00:00
ioutil.c helper/command: change prototype of command_print/command_print_sameline 2019-05-14 19:37:11 +01:00
ioutil.h Make #include guard naming consistent 2016-05-24 22:30:55 +01:00
ioutil_stubs.c Remove FSF address from GPL notices 2016-05-24 22:30:01 +01:00
jep106.c Remove FSF address from GPL notices 2016-05-24 22:30:01 +01:00
jep106.h Make #include guard naming consistent 2016-05-24 22:30:55 +01:00
jep106.inc helper: Update jep106 database to JEP106AT 2016-12-08 12:30:14 +00:00
jim-nvp.c jim-nvp: Make Jim_GetOpt_String const-correct 2016-02-29 20:32:31 +00:00
jim-nvp.h Make #include guard naming consistent 2016-05-24 22:30:55 +01:00
list.h Make #include guard naming consistent 2016-05-24 22:30:55 +01:00
log.c helper/command: change prototype of command_print/command_print_sameline 2019-05-14 19:37:11 +01:00
log.h Add RISC-V support. 2018-07-24 13:07:26 +01:00
options.c helper/options: Add missing #include for MinGW and MSYS2 2017-10-03 11:18:20 +01:00
replacements.c Remove FSF address from GPL notices 2016-05-24 22:30:01 +01:00
replacements.h helper/replacements.h: Add missing #include 2018-03-07 23:43:58 +00:00
startup.tcl helper/command: do not replace new commands with ocd_ prefix 2019-05-14 19:38:43 +01:00
system.h Make #include guard naming consistent 2016-05-24 22:30:55 +01:00
time_support.c Add timeval_compare helper function 2018-01-25 16:43:45 +00:00
time_support.h Add timeval_compare helper function 2018-01-25 16:43:45 +00:00
time_support_common.c Fix usage of timeval_ms() 2016-07-19 10:45:16 +01:00
types.h helper/types: cast to uint32_t,uint16_t to avoid UB by shifting int too far 2018-03-12 14:12:07 +00:00
update_jep106.pl helper: Add converter from JEP106 ID to manufacturer name 2016-01-22 15:02:16 +00:00
util.c Remove FSF address from GPL notices 2016-05-24 22:30:01 +01:00
util.h Make #include guard naming consistent 2016-05-24 22:30:55 +01:00