summaryrefslogtreecommitdiffstats
path: root/games
diff options
context:
space:
mode:
authorceri <ceri@FreeBSD.org>2003-12-27 16:04:41 +0000
committerceri <ceri@FreeBSD.org>2003-12-27 16:04:41 +0000
commit17cbb0b2fcccafb2cdb9dd67f20df66a07be9522 (patch)
treee164e2686e2822582da96ba754a34ab5b6d21d7b /games
parent7cc51bb81dffa23ebee6defec1beb8637bf419a7 (diff)
downloadFreeBSD-src-17cbb0b2fcccafb2cdb9dd67f20df66a07be9522.zip
FreeBSD-src-17cbb0b2fcccafb2cdb9dd67f20df66a07be9522.tar.gz
Stop "fortune -l" from looping forever.
PR: bin/58730 Submitted by: pak <pak@cns.utoronto.ca>
Diffstat (limited to 'games')
-rw-r--r--games/fortune/fortune/fortune.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/games/fortune/fortune/fortune.c b/games/fortune/fortune/fortune.c
index 3234d2d..92114ca 100644
--- a/games/fortune/fortune/fortune.c
+++ b/games/fortune/fortune/fortune.c
@@ -282,7 +282,7 @@ fortlen()
char line[BUFSIZ];
if (!(Fortfile->tbl.str_flags & (STR_RANDOM | STR_ORDERED)))
- nchar = (Seekpts[1] - Seekpts[0] <= SLEN);
+ nchar = (int)(Seekpts[1] - Seekpts[0]);
else {
open_fp(Fortfile);
(void) fseek(Fortfile->inf, Seekpts[0], 0);
OpenPOWER on IntegriCloud