ftop-0001-overflow.patch 567 B

1234567891011121314151617
  1. Set tmp_buf and rate_buf to something ridiculously high to fix a buffer
  2. overflow when COLUMNS is large. - JeR
  3. (Taken from gentoo portage)
  4. Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar>
  5. --- a/src/ftop.c 2009-02-16 07:00:00.000000000 +0100
  6. +++ b/src/ftop.c 2013-09-06 14:42:41.788852952 +0200
  7. @@ -736,7 +736,7 @@
  8. {
  9. size_t i, j, bytes, bar_total;
  10. char more_procs_ch, more_files_ch, expanded_ch;
  11. - char tmp_buf[80], rate_buf[80];
  12. + char tmp_buf[2048], rate_buf[2048];
  13. char *tmp_str;
  14. snapshot *s, *s_prev;
  15. file_info *tmp_file;