diff options
author | Guillem Jover <guillem@debian.org> | 2019-10-02 04:04:59 +0200 |
---|---|---|
committer | Guillem Jover <guillem@debian.org> | 2019-10-30 22:02:48 +0100 |
commit | 8da9c02a82840b6dbcecedfbc8e19264efd4dcbe (patch) | |
tree | 43202cf3b1252c9cd7c2e11d10324160f6f87974 /dselect | |
parent | 4cc04c4d9f8f5e8e7a2b19571836c69b7f382d45 (diff) | |
download | dpkg-8da9c02a82840b6dbcecedfbc8e19264efd4dcbe.tar.gz |
dselect: Make baselist::draw_column_*() col arguments const
Warned-by: cppcheck
Fixes: constParameter
Diffstat (limited to 'dselect')
-rw-r--r-- | dselect/baselist.cc | 6 | ||||
-rw-r--r-- | dselect/dselect.h | 6 |
2 files changed, 6 insertions, 6 deletions
diff --git a/dselect/baselist.cc b/dselect/baselist.cc index 6fd769239..4fa7f22b5 100644 --- a/dselect/baselist.cc +++ b/dselect/baselist.cc @@ -135,19 +135,19 @@ baselist::end_column(column &col, const char *title) } void -baselist::draw_column_head(column &col) +baselist::draw_column_head(const column &col) { mvwaddnstr(colheadspad, 0, col.x, col.title, col.width); } void -baselist::draw_column_sep(column &col, int y) +baselist::draw_column_sep(const column &col, int y) { mvwaddch(listpad, y, col.x - 1, ' '); } void -baselist::draw_column_item(column &col, int y, const char *item) +baselist::draw_column_item(const column &col, int y, const char *item) { mvwprintw(listpad, y, col.x, "%-*.*s", col.width, col.width, item); } diff --git a/dselect/dselect.h b/dselect/dselect.h index 383fb9516..e620f5af8 100644 --- a/dselect/dselect.h +++ b/dselect/dselect.h @@ -87,9 +87,9 @@ protected: void add_column(column &col, const char *title, int width); void end_column(column &col, const char *title); - void draw_column_head(column &col); - void draw_column_sep(column &col, int y); - void draw_column_item(column &col, int y, const char *item); + void draw_column_head(const column &col); + void draw_column_sep(const column &col, int y); + void draw_column_item(const column &col, int y, const char *item); // (n)curses stuff WINDOW *listpad, *infopad, *colheadspad, *thisstatepad; |