perry [Sun, 27 Jan 2002 00:35:16 +0000 (00:35 +0000)]
Temporarily add a "MKHIDEGAME" variable that by default blocks the
"install some games into /usr/games/hide" dance. This is ?='ed to "no"
at the top of the file.
XXX What we should do ultimately is either add this to bsd.own.mk or
rename it to MKDM and also have it control whether dm(8) is built at all.
proff [Sat, 20 Oct 2001 09:33:39 +0000 (09:33 +0000)]
Fortune is not moribund.
Add Farberisms from Prof. Dave Farber.
From: David Farber <dave@farber.net>
To: proff@iq.org (Julian Assange)
Date: Sat, 20 Oct 2001 03:29:08 -0400
Subject: Re: farberisms
Fine with me
At 02:27 PM 10/20/2001 +1000, you wrote:
>Hi Dave,
>
>I've just come accross your list of `Farberisms', which had me in
>stiches. As these are deliciously `fortune'esqe, I'd like to add
>them to the NetBSD distribution. Do you have any objections?
>
>Cheers,
>Julian.
va_{start,end} audit:
Make sure that each va_start has one and only one matching va_end,
especially in error cases.
If the va_list is used multiple times, do multiple va_starts/va_ends.
If a function gets va_list as argument, don't let it use va_end (since
it's the callers responsibility).
Improved by comments from enami and christos -- thanks!
Heimdal/krb4/KAME changes already fed back, rest to follow.
Fix typos and spelos. Add and correct some attributions. Add a
couple of fortunes. Canonize quotes. Remove duplicate fortunes.
Correct author names.
Mostly from FreeBSD and OpenBSD.
jsm [Fri, 31 Aug 2001 07:17:02 +0000 (07:17 +0000)]
Always lseek back to the beginning of the file in post(), which may be
called twice in a game if a bonus occurs. Patch from Malcolm Parsons
<malcolm@ivywell.screaming.net>.
jsm [Fri, 31 Aug 2001 07:15:44 +0000 (07:15 +0000)]
Keep track of visible worm length. If nowhere is available for the
new prize, have the player win rather than hanging. Bug reported by
Malcolm Parsons <malcolm@ivywell.screaming.net>.
jsm [Thu, 30 Aug 2001 10:49:50 +0000 (10:49 +0000)]
Check for screen sizes that are too small. Fix off-by-one error in
trying to place the prize. Position the score appropriately for
screens that may not be 80 columns wide.
atatat [Wed, 15 Aug 2001 17:25:42 +0000 (17:25 +0000)]
Change -a to mean all files, as opposed to just a few more files.
Modify the regex handling so that we can match fortunes in rot13'ed
databases (rot13 the pattern and maintain a second compiled pattern)
and rot13 the rot13'ed fortune before output.
Move the rot13 code to a function since it's now used in three places
instead of just one.
Initialize posfile in one place since it appears to get used without
being initialized when using debugging.
Make a *slight* improvement to the random seeding by squaring the pid
and then xor'ing against the current time, since just xor'ing the time
with the pid will not change if they both advance by one from "odd" to
"even".
wiz [Thu, 9 Aug 2001 13:02:49 +0000 (13:02 +0000)]
Fix for FreeBSD/13278, from FreeBSD:
When a game ends that makes the top 10, the function insert_score in
score.c is called to make the new score file. But the case for KFIRE
(killed by fire) incorrectly uses strcpy instead of strcat (all the
other cases use strcat). This puts the string in the wrong place and
corrupts the score file.
christos [Mon, 4 Jun 2001 21:21:42 +0000 (21:21 +0000)]
Overhaul error handling and reporting for regular expressions.
Provide a RE_OK() macro that tests if the current compiled pattern
works and a RE_ERROR() macro that prints what went wrong as well
as the particular RE implementation can handle.
jsm [Sun, 25 Mar 2001 20:43:58 +0000 (20:43 +0000)]
Make mostly gcc -W clean, and other cleanup:
Use const.
Add __noreturn__ attributes.
Add a __format__ attribute.
Add __unused__ attributes.
Use symbolic constants for open() and lseek().
Declare types of all function parameters; convert some function
definitions to ISO C form.
Ensure standard file descriptors are open on startup.
Check for errors writing output of makedefs.
Avoid duplicate definitions of variables.