diff options
author | Jonathan McCrohan <jmccrohan@gmail.com> | 2020-07-29 23:11:46 +0100 |
---|---|---|
committer | Jonathan McCrohan <jmccrohan@gmail.com> | 2020-07-29 23:11:46 +0100 |
commit | 8deb3660926fe8278948b898b9c1b772eed2e61e (patch) | |
tree | cc46239969468c1f4017da7aac5420664b5bbd22 /conf_scr.c | |
parent | 1fc41b776f712f321c1f355d391c6a5eaf79ebfa (diff) | |
download | wavemon-8deb3660926fe8278948b898b9c1b772eed2e61e.tar.gz |
New upstream version 0.9.1upstream/0.9.1upstream
Diffstat (limited to 'conf_scr.c')
-rw-r--r-- | conf_scr.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -51,7 +51,7 @@ static void waddstr_item(WINDOW *w, int y, struct conf_item *item, char hilight) break; case t_list: assert(item->list && item->list[*item->v.i]); - strncpy(s, item->list[*item->v.i], sizeof(s)); + strncpy(s, item->list[*item->v.i], sizeof(s)-1); /* Fall through, dummy statements to pacify gcc -Wall */ case t_sep: case t_func: @@ -90,7 +90,7 @@ static void waddstr_item(WINDOW *w, int y, struct conf_item *item, char hilight) } } -static void change_item(int inum, char sign) +static void change_item(int inum, int sign) { struct conf_item *item = ll_get(conf_items, inum); int tmp; @@ -139,7 +139,7 @@ static int m_pref(WINDOW *w_conf, int list_offset, int active_item, int num_item for (active_line = i = j = 0; i < num_items; i++) { struct conf_item *item = ll_get(conf_items, i); - if (!item->dep || *item->dep) { + if (!item->hidden && (!item->dep || *item->dep)) { if (i != active_item) waddstr_item(w_conf, j++, item, 0); else { |