1
0
mirror of https://github.com/openbsd/src.git synced 2025-01-10 06:47:55 -08:00

Obvious bugfix: requesting a long dictum from a file containing short

ones only or vice versa is an error rather than a recipe for success.
This commit is contained in:
schwarze 2021-01-03 01:32:13 +00:00
parent 6e88d42dcd
commit c3f0a71bac

View File

@ -1,4 +1,4 @@
/* $OpenBSD: fortune.c,v 1.62 2021/01/02 21:35:11 schwarze Exp $ */
/* $OpenBSD: fortune.c,v 1.63 2021/01/03 01:32:13 schwarze Exp $ */
/* $NetBSD: fortune.c,v 1.8 1995/03/23 08:28:40 cgd Exp $ */
/*-
@ -165,7 +165,7 @@ main(int ac, char *av[])
init_prob();
if ((Short_only && minlen_in_list(File_list) > SLEN) ||
(Long_only && maxlen_in_list(File_list) <= SLEN))
return 0;
return 1;
do {
get_fort();