summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorsabetts <sabetts>2001-06-05 09:15:29 +0000
committersabetts <sabetts>2001-06-05 09:15:29 +0000
commit20ccc501f79c79ad0f74287f48c7e108144db149 (patch)
tree7a7d0bba02c088e71f722ad8ad53ba105ca0b1ec
parent622ea708ef80c3044838f32837254c6f74fe793e (diff)
downloadratpoison-20ccc501f79c79ad0f74287f48c7e108144db149.zip
(parse_keydesc): return NULL if the keydesc is a
'-'.
-rw-r--r--ChangeLog3
-rw-r--r--src/actions.c6
2 files changed, 9 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index 8604b22..8b41eff 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
2001-06-05 shawn <sabetts@diggin.lamenet.tmp>
+ * src/actions.c (parse_keydesc): return NULL if the keydesc is a
+ '-'.
+
* src/manage.c (hide_window): ignore only StructureNotify events.
* src/data.h (WIN_EVENTS): Add StructureNotifyMask.
diff --git a/src/actions.c b/src/actions.c
index 6bf0d06..9a2db18 100644
--- a/src/actions.c
+++ b/src/actions.c
@@ -231,6 +231,12 @@ parse_keydesc (char *keydesc)
/* Its got hyphens, so parse out the modifiers and keysym */
token = strtok (keydesc, "-");
+ if (token == NULL)
+ {
+ /* It was nothing but hyphens */
+ return NULL;
+ }
+
do
{
next_token = strtok (NULL, "-");