Date: Fri, 8 Aug 2008 02:46:47 +0000 (UTC) From: "Andrey A. Chernov" <ache@FreeBSD.org> To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org Subject: cvs commit: src/games/random randomize_fd.c Message-ID: <200808080247.m782l3fi073098@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
ache 2008-08-08 02:46:47 UTC FreeBSD src repository Modified files: games/random randomize_fd.c Log: SVN rev 181412 on 2008-08-08 02:46:47Z by ache 1) Fix longstanding math bug with denominator > 1 (wrong probability). Test case: random -f some_small_file 10000 (in most cases must be no output) 2) Prevent number of lines > RANDOM_MAX (overflow or nothing may be choosed) with EFBIG err() 3) After line is found, terminate list loop for -U case too, since nothing to do in the rest of the loop left. Revision Changes Path 1.5 +16 -8 src/games/random/randomize_fd.c
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200808080247.m782l3fi073098>