[flac-dev] [PATCH] for console width detection

Erik de Castro Lopo mle+la at mega-nerd.com
Tue Jul 8 01:27:40 PDT 2014


lvqcl wrote:

> A bug was reported here:
> https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=739613
> 
> get_console_width() may return 0, and there will be division by 0
> in stats_print_name():
> 
> 	console_width = get_console_width();
> 	len = strlen_console(name)+2;
> 	console_chars_left = console_width  - (len % console_width);
> 
> A simple patch is attached.

Applied. Thanks.

Erik
-- 
----------------------------------------------------------------------
Erik de Castro Lopo
http://www.mega-nerd.com/


More information about the flac-dev mailing list