summaryrefslogtreecommitdiffstats
path: root/status.c
diff options
context:
space:
mode:
authornicm <nicm>2019-04-25 19:36:59 +0000
committernicm <nicm>2019-04-25 19:36:59 +0000
commit2d65bbd94129c4542394a83151cb1a131c3c7871 (patch)
tree0020978c837b96ad83516e47ff5f3974a2b22649 /status.c
parenta609e6361a2dd9a7ec6d9dd8dfd80d86d38c033b (diff)
options_array_item_value cannot return NULL.
Diffstat (limited to 'status.c')
-rw-r--r--status.c7
1 files changed, 1 insertions, 6 deletions
diff --git a/status.c b/status.c
index 1a11a564..34ed3778 100644
--- a/status.c
+++ b/status.c
@@ -1293,7 +1293,6 @@ status_prompt_complete_list(u_int *size, const char *s)
size_t slen = strlen(s), valuelen;
struct options_entry *o;
struct options_array_item *a;
- union options_value *ov;
const char *layouts[] = {
"even-horizontal", "even-vertical", "main-horizontal",
"main-vertical", "tiled", NULL
@@ -1322,11 +1321,7 @@ status_prompt_complete_list(u_int *size, const char *s)
if (o != NULL) {
a = options_array_first(o);
while (a != NULL) {
- ov = options_array_item_value(a);
- if (ov == NULL)
- goto next;
-
- value = ov->string;
+ value = options_array_item_value(a)->string;
if ((cp = strchr(value, '=')) == NULL)
goto next;
valuelen = cp - value;