From: Ben Gras Date: Sun, 21 Dec 2008 04:01:01 +0000 (+0000) Subject: stopgap measure against elvis going nuts when files that are too large X-Git-Tag: v3.1.4~156 X-Git-Url: http://zhaoyanbai.com/repos/%22http:/www.isc.org/icons/nslookup.html?a=commitdiff_plain;h=523fdf272938e2102047ef3ac66daa1c9652a141;p=minix.git stopgap measure against elvis going nuts when files that are too large are opened. --- diff --git a/commands/elvis/tmp.c b/commands/elvis/tmp.c index 77ae0ef88..9102169d8 100755 --- a/commands/elvis/tmp.c +++ b/commands/elvis/tmp.c @@ -367,6 +367,9 @@ int tmpstart(filename) } nbytes++; } + if(i >= MAXBLKS) { + FAIL("Too many blocks: %d.", i); + } lnum[i - 1] = nlines; } FoundEOF: