Commit Graph

18 Commits

Author SHA1 Message Date
drochner
432ec04420 if initscr() fails, exit with a message rather than crash in the
next curses call
2008-08-08 16:10:47 +00:00
dholland
130a8172b6 ANSIfy. Remove unnecessary casts. Clean up for -Wsign-compare. Make more
things file-static. Other minor tidyups, and fix a couple minor bugs found
along the way.
2008-01-14 03:50:01 +00:00
dholland
23c02a454f Whitespace/KNF nits. 2008-01-14 00:23:51 +00:00
dholland
e94a5bc9f9 Comprehensive (or at least extensive) string handling cleanup for rogue.
This patch dates (mostly) back to 2002; the critical parts of it were
handled back then by security-officer. As far as I know, there's
nothing exploitable fixed herein.

A slightly earlier version of this patch was reviewed by Christian Biere
when I filed it as PR 34750.
2007-12-27 23:52:59 +00:00
perry
8b0f9554ff convert __attribute__s to applicable cdefs.h macros 2007-12-15 19:44:37 +00:00
agc
e5aeb4ea46 Move UCB-licensed code from 4-clause to 3-clause licence.
Patches provided by Joel Baker in PR 22269, verified by myself.
2003-08-07 09:36:50 +00:00
blymn
7147df1ef5 Change deprecated curses call to new equivalent. 2001-12-06 12:19:44 +00:00
matt
3233065035 More include additions for exit, abs, strcmp, etc. 2000-07-03 03:57:39 +00:00
jsm
5367f3400c Security improvements for games (largely from or inspired by OpenBSD).
Games which run setgid from dm, but don't need to, should drop their
privileges at startup.

Games which have a scorefile should open it at startup, then drop all
privileges leaving just the open writable file descriptor.  If the
game can invoke subprocesses, this should be made close-on-exec.

Games with scorefiles should make sure they do not get a file
descriptor < 3.  (Otherwise, they could get confused and corrupt the
scorefile when using stdin, stdout or stderr.)

Some old setuid revokes from the days of setuid games change into gid
revokes.
1999-09-12 09:02:20 +00:00
jsm
a9c7f9b096 Check for failure of malloc() and calloc() at various places in the games. 1999-09-09 17:27:58 +00:00
jsm
b03d4fa882 Add __noreturn__' and __unused__' attributes where appropriate to
the games.

This merges in all such remaining changes from the Linux port of the
NetBSD games, except in hunt (where substantial changes from OpenBSD
need to be looked at).

Most noreturn attributes were previously added in bin/6144, with some
others that were missed then in bin/8082.  Previous `unused'
attributes were covered in bin/6557, bin/8058 and other PRs (all these
PRs have already been handled and closed).
1999-09-08 21:45:25 +00:00
hubertf
6d265b3268 constify, per PR 6148 1998-11-10 13:01:31 +00:00
mycroft
a6bb9f4ef1 const poisoning. 1998-07-27 01:12:35 +00:00
lukem
2736b51163 WARNSify (not an insignificant task...) 1997-10-12 11:45:01 +00:00
mycroft
c35b410216 Use POSIX tty semantics. 1995-04-28 23:49:19 +00:00
cgd
7ee35daafd clean up import, NetBSD RCS Ids 1995-04-22 10:27:22 +00:00
mycroft
8542364e07 Add RCS identifiers. 1993-08-01 18:49:50 +00:00
cgd
61f282557f initial import of 386bsd-0.1 sources 1993-03-21 09:45:37 +00:00