Atoptool/atop

compile warnings in 2.9.0, -Wformat-security

Zugschlus opened this issue · 1 comments

cc -g -O2 -ffile-prefix-map=/home/mh/packages/atop/build-area/atop-2.9.0=. -fstack-protector-strong -Wformat -Werror=format-security -O2 -I. -Wall -Wno-stringop-truncation -Wmissing-prototypes -Wmissing-declarations  -Wdate-time -D_FORTIFY_SOURCE=2  -c -o showlinux.o showlinux.c
drawbar.c: In function ‘drawevent’:
drawbar.c:2058:9: error: format not a string literal and no format arguments [-Werror=format-security]
 2058 |         mvwprintw(w->win, line, column, text);
      |         ^~~~~~~~~
drawbar.c: In function ‘headergetch’:
drawbar.c:2108:17: error: format not a string literal and no format arguments [-Werror=format-security]
 2108 |                 mvwprintw(headwin, 0, statcol, statusmsg);
      |                 ^~~~~~~~~
drawbar.c: In function ‘getwininput’:
drawbar.c:2331:9: error: format not a string literal and no format arguments [-Werror=format-security]
 2331 |         mvwprintw(mywin, 1, 1, prompt);
      |         ^~~~~~~~~

Is this intended? If not, could this be fixed, removing the warning?

Debian compiles with an option that treats all warnings as errors and thus would need tweaking to build this. I'd rather not do this.

This issue has been fixed already by pull request #262.