diff options
author | okan <okan> | 2014-01-20 21:34:32 +0000 |
---|---|---|
committer | okan <okan> | 2014-01-20 21:34:32 +0000 |
commit | d91571c567fc74c422d766fd2613c9ae23ccbc36 (patch) | |
tree | d5aa253fdcbb4860caee0dd4b7af7f11017dbcfa /conf.c | |
parent | 7263fb4c8457631a921c20a93bb339dfe638bb34 (diff) | |
download | cwm-d91571c567fc74c422d766fd2613c9ae23ccbc36.tar.gz cwm-d91571c567fc74c422d766fd2613c9ae23ccbc36.tar.xz cwm-d91571c567fc74c422d766fd2613c9ae23ccbc36.zip |
constify and rename some confusing variables around cmdq.
Diffstat (limited to 'conf.c')
-rw-r--r-- | conf.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/conf.c b/conf.c index edf7c7e..57dd344 100644 --- a/conf.c +++ b/conf.c @@ -37,23 +37,23 @@ static void conf_unbind_mouse(struct conf *, struct mousebinding *); /* Add an command menu entry to the end of the menu */ void -conf_cmd_add(struct conf *c, char *image, char *label) +conf_cmd_add(struct conf *c, const char *name, const char *path) { /* "term" and "lock" have special meanings. */ - if (strcmp(label, "term") == 0) - (void)strlcpy(c->termpath, image, sizeof(c->termpath)); - else if (strcmp(label, "lock") == 0) - (void)strlcpy(c->lockpath, image, sizeof(c->lockpath)); + if (strcmp(name, "term") == 0) + (void)strlcpy(c->termpath, path, sizeof(c->termpath)); + else if (strcmp(name, "lock") == 0) + (void)strlcpy(c->lockpath, path, sizeof(c->lockpath)); else { struct cmd *cmd = xmalloc(sizeof(*cmd)); - (void)strlcpy(cmd->image, image, sizeof(cmd->image)); - (void)strlcpy(cmd->label, label, sizeof(cmd->label)); + (void)strlcpy(cmd->name, name, sizeof(cmd->name)); + (void)strlcpy(cmd->path, path, sizeof(cmd->path)); TAILQ_INSERT_TAIL(&c->cmdq, cmd, entry); } } void -conf_autogroup(struct conf *c, int no, char *val) +conf_autogroup(struct conf *c, int no, const char *val) { struct autogroupwin *aw; char *p; @@ -74,7 +74,7 @@ conf_autogroup(struct conf *c, int no, char *val) } void -conf_ignore(struct conf *c, char *val) +conf_ignore(struct conf *c, const char *val) { struct winmatch *wm; |