diff options
author | trociny <trociny@FreeBSD.org> | 2013-04-21 20:51:53 +0000 |
---|---|---|
committer | trociny <trociny@FreeBSD.org> | 2013-04-21 20:51:53 +0000 |
commit | 761a3d22a7f983f7055431f4d002c59554d8df87 (patch) | |
tree | d92cfe9859e4e54af8e593b633bd1b66514ed6ba | |
parent | 1b871737069c245a9c5577b30281da8601613bcf (diff) | |
download | FreeBSD-src-761a3d22a7f983f7055431f4d002c59554d8df87.zip FreeBSD-src-761a3d22a7f983f7055431f4d002c59554d8df87.tar.gz |
Remove code duplication.
-rw-r--r-- | sbin/hastctl/hastctl.c | 12 |
1 files changed, 1 insertions, 11 deletions
diff --git a/sbin/hastctl/hastctl.c b/sbin/hastctl/hastctl.c index 883a298..6fe55fa 100644 --- a/sbin/hastctl/hastctl.c +++ b/sbin/hastctl/hastctl.c @@ -504,18 +504,8 @@ main(int argc, char *argv[]) nv_add_string(nv, argv[ii + 1], "resource%d", ii); break; case CMD_LIST: - /* Obtain verbose status of the given resources. */ - nv = nv_alloc(); - nv_add_uint8(nv, HASTCTL_CMD_STATUS, "cmd"); - if (argc == 0) - nv_add_string(nv, "all", "resource%d", 0); - else { - for (ii = 0; ii < argc; ii++) - nv_add_string(nv, argv[ii], "resource%d", ii); - } - break; case CMD_STATUS: - /* Obtain brief status of the given resources. */ + /* Obtain status of the given resources. */ nv = nv_alloc(); nv_add_uint8(nv, HASTCTL_CMD_STATUS, "cmd"); if (argc == 0) |