summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorsabetts <sabetts>2001-09-18 07:31:31 +0000
committersabetts <sabetts>2001-09-18 07:31:31 +0000
commitba06c2bdff1848475cad6f6ccc8bea43397ac839 (patch)
tree2c2a4993d76a2ad7017dc097d26c6529d14cf3e2 /src
parent47f2a130df7a108ef23588b4cc842e393d2f5f51 (diff)
downloadratpoison-ba06c2bdff1848475cad6f6ccc8bea43397ac839.zip
* src/actions.c(cmd_defwinpos): abort if data is NULL
(cmd_deftranspos): likewise (cmd_defmaxsizepos): likewise (cmd_defmaxsizepos): Use the correct command name in call to message. (cmd_deftranspos): likewise (cmd_defwinpos): likewise
Diffstat (limited to 'src')
-rw-r--r--src/actions.c25
1 files changed, 22 insertions, 3 deletions
diff --git a/src/actions.c b/src/actions.c
index 5efcd10..80b1e98 100644
--- a/src/actions.c
+++ b/src/actions.c
@@ -1385,13 +1385,14 @@ cmd_pos (int interactive, void *data)
int pos;
rp_window *win;
- if (current_window() == NULL) return NULL;
if (data == NULL)
{
message (" pos: Two arguments needed ");
return NULL;
}
+ if (current_window() == NULL) return NULL;
+
win = current_window();
if ((pos = parse_winpos (data)) < 0)
@@ -1412,9 +1413,15 @@ cmd_defwinpos (int interactive, void *data)
{
int pos;
+ if (data == NULL)
+ {
+ message (" defwinpos: Two arguments needed ");
+ return NULL;
+ }
+
if ((pos = parse_winpos (data)) < 0)
{
- message (" pos: Unknown position ");
+ message (" defwinpos: Unknown position ");
}
else
{
@@ -1429,6 +1436,12 @@ cmd_deftranspos (int interactive, void *data)
{
int pos;
+ if (data == NULL)
+ {
+ message (" deftranspos: Two arguments needed ");
+ return NULL;
+ }
+
if ((pos = parse_winpos (data)) < 0)
{
message (" pos: Unknown position ");
@@ -1446,9 +1459,15 @@ cmd_defmaxsizepos (int interactive, void *data)
{
int pos;
+ if (data == NULL)
+ {
+ message (" defmaxsizepos: Two arguments needed ");
+ return NULL;
+ }
+
if ((pos = parse_winpos (data)) < 0)
{
- message (" pos: Unknown position ");
+ message (" defmaxsizepos: Unknown position ");
}
else
{