diff options
author | Zachary T Welch <zw@superlucidity.net> | 2009-11-28 10:46:53 -0800 |
---|---|---|
committer | Zachary T Welch <zw@superlucidity.net> | 2009-11-28 13:00:39 -0800 |
commit | 2da2864632c281a2523f924b406e532d610857a6 (patch) | |
tree | 1b2805bfec5ceaec8ad68b7df3423c684595ab8a | |
parent | 8795b8f9df5ba1fd8466a04b515aa5f56c0c4015 (diff) | |
download | openocd_libswd-2da2864632c281a2523f924b406e532d610857a6.tar.gz openocd_libswd-2da2864632c281a2523f924b406e532d610857a6.tar.bz2 openocd_libswd-2da2864632c281a2523f924b406e532d610857a6.tar.xz openocd_libswd-2da2864632c281a2523f924b406e532d610857a6.zip |
remove redundant 'rm' command handler
Two 'rm' commands were implemented and registered. This removes the
version that would have never been called prior to refactoring the
command registration.
-rw-r--r-- | src/helper/ioutil.c | 27 |
1 files changed, 0 insertions, 27 deletions
diff --git a/src/helper/ioutil.c b/src/helper/ioutil.c index e13f5902..ed82ba1c 100644 --- a/src/helper/ioutil.c +++ b/src/helper/ioutil.c @@ -38,9 +38,6 @@ #ifdef HAVE_NET_IF_H #include <net/if.h> #endif -//#ifdef HAVE_NETINET_TCP_H -//#include <netinet/tcp.h> -//#endif #ifdef HAVE_SYS_IOCTL_H #include <sys/ioctl.h> #endif @@ -57,23 +54,6 @@ #endif -COMMAND_HANDLER(handle_rm_command) -{ - if (CMD_ARGC != 1) - { - command_print(CMD_CTX, "rm <filename>"); - return ERROR_INVALID_ARGUMENTS; - } - - if (unlink(CMD_ARGV[0]) != 0) - { - command_print(CMD_CTX, "failed: %d", errno); - } - - return ERROR_OK; -} - - /* loads a file and returns a pointer to it in memory. The file contains * a 0 byte(sentinel) after len bytes - the length of the file. */ int loadFile(const char *fileName, void **data, size_t *len) @@ -645,13 +625,6 @@ static int zylinjtag_Jim_Command_mac(Jim_Interp *interp, int argc, static const struct command_registration ioutil_command_handlers[] = { { - .name = "rm", - .handler = &handle_rm_command, - .mode = COMMAND_ANY, - .help = "remove file", - .usage= "<file_name>", - }, - { .name = "cat", .handler = &handle_cat_command, .mode = COMMAND_ANY, |