summaryrefslogtreecommitdiff
path: root/src/actions.c
diff options
context:
space:
mode:
authorJérémie Courrèges-Anglas <jca@wxcvbn.org>2014-03-05 03:00:44 +0100
committerJérémie Courrèges-Anglas <jca@wxcvbn.org>2014-03-24 10:22:55 +0100
commit977bfad903c35f1e33fc978289404226ac0693e9 (patch)
tree4612f825fc0c24947fe2390470648ea42f1deca9 /src/actions.c
parent77176d78b15a702d47725738df01eace86ebfa07 (diff)
downloadratpoison-977bfad903c35f1e33fc978289404226ac0693e9.zip
Kill code and simplify cmd_number
* cmd_number needs at least one argument * The code that handled the zero argument case was thus unreachable, and was the last user of print_window_information, so kill that function.
Diffstat (limited to 'src/actions.c')
-rw-r--r--src/actions.c15
1 files changed, 4 insertions, 11 deletions
diff --git a/src/actions.c b/src/actions.c
index fa35ae9..887322e 100644
--- a/src/actions.c
+++ b/src/actions.c
@@ -2768,13 +2768,6 @@ cmd_number (int interactive UNUSED, struct cmdarg **args)
int old_number, new_number;
rp_window_elem *other_win, *win;
- if (args[0] == NULL)
- {
- /* XXX: Fix this. */
- print_window_information (rp_current_group, current_window());
- return cmdret_new (RET_SUCCESS, NULL);
- }
-
/* Gather the args. */
new_number = ARG(0,number);
if (args[1])
@@ -4485,9 +4478,9 @@ cmd_restart (int interactive UNUSED, struct cmdarg **args UNUSED)
}
cmdret *
-cmd_startup_message (int interactive, struct cmdarg **args)
+cmd_startup_message (int interactive UNUSED, struct cmdarg **args)
{
- if (args[0] == NULL && !interactive)
+ if (args[0] == NULL)
return cmdret_new (RET_SUCCESS, "%s", defaults.startup_message ? "on":"off");
if (!strcasecmp (ARG_STRING(0), "on"))
@@ -4648,9 +4641,9 @@ cmd_sselect(int interactive UNUSED, struct cmdarg **args)
}
cmdret *
-cmd_warp (int interactive, struct cmdarg **args)
+cmd_warp (int interactive UNUSED, struct cmdarg **args)
{
- if (args[0] == NULL && !interactive)
+ if (args[0] == NULL)
return cmdret_new (RET_SUCCESS, "%s", defaults.warp ? "on":"off");
if (!strcasecmp (ARG_STRING(0), "on"))