Commit Graph

537 Commits

Author SHA1 Message Date
simonb 6372fa90cc Remove unneeded "mips compiler bug" workaround from original code imported
in 1994.
1999-02-11 02:34:24 +00:00
hubertf b0ed16a714 tgetent() handles const correctly in current 1999-02-10 17:08:06 +00:00
hubertf 752e969da2 Add __attribute__() to a variable. From PR 6557, after discussion with
Joseph S. Myers <jsm28@cam.ac.uk>
1999-02-10 12:38:54 +00:00
hubertf 92932dfcc8 The patch below makes the game backgammon(6) use `const' where
appropriate.  It also removes some obsolete, unused code to check the
number of users on the system (obsoleted by dm); removes a prototype
for an unused function that was removed earlier; and removes a control
character from one message that was I think intended to clear the
screen on some particular terminal (though I can't find the comment to
that effect in any of the BSD source trees I have handy) but no longer
serves any useful purpose.

From PR 6580 by Joseph Myers <jsm28@cam.ac.uk>.

Also contains two more patches, one in teachgammon/tutor.h (by Joseph)
and one in common_source/fancy.c (by me).
1999-02-10 12:29:47 +00:00
hubertf ce3b092b6d Only invoke pager given in $PAGER if output goes to a tty, feed pager
via stdin, per PR 6699 by Joseph Myers <jsm28@cam.ac.uk>
1999-02-10 01:44:34 +00:00
hubertf bd8be7848a Const poisoning, per PR 6660 by Joseph Myers <jsm28@cam.ac.uk> 1999-02-10 01:36:50 +00:00
hubertf 24f809b060 The game sail(6) has a function Write() which is used both with
integer arguments and with string arguments (cast to long, and in one
place to int).  The patch here cleans this up, making it into two
separate functions; this allows for the game to be made const-correct
in future and improves portability.

The patch also contains two other fragments: a change to use the
symbolic constant SEEK_END with fseek(), and a change to use snprintf
in one place to avoid a buffer overrun.

Via PR 6569 by Joseph Myers <jsm28@cam.ac.uk>.
1999-02-10 00:45:45 +00:00
hubertf c7bcded63e The patch below does some minor cleanup of adventure(6): an additional
use of const I missed in bin/6041; avoiding a signed/unsigned warning;
marking an unused parameter as such; revoking setgid privileges
(including the saved gid) rather than setuid ones; includes and
function prototypes in setup.c; the string passed to err() should not
end with a `.'.  Together with the patch sent concerning adventure's
EOF handling, this synchronises adventure(6) in NetBSD with the Linux
port of the NetBSD games.

Via PR 6557 by Joseph Myers <jsm28@cam.ac.uk>
1999-02-10 00:29:21 +00:00
hubertf 08ab0f321a The game adventure(6) handles EOF on standard input rather
ungracefully.  The patch, derived from OpenBSD, improves this
handling.

Sent in in PR 6556 by Joseph Myers <jsm28@cam.ac.uk>.
1999-02-10 00:11:28 +00:00
hubertf 6cfbee5947 only show preview if the -p option is given 1999-01-03 17:13:51 +00:00
hubertf 13aa60478d document morse's decode option -d 1999-01-03 17:12:28 +00:00
hubertf f42c52bee6 Add previewing of next shape. Old (previous) behaviour can be
restored by compiling with NO_PREVIEW defined.
1999-01-03 02:00:17 +00:00
tron 1c7a4fb141 Remove obsolete header file. Fixes PR bin/6700 by Joseph S. Myers. 1999-01-02 15:47:55 +00:00
dbj 16a09f01ca tweaks to pass DESTDIR to subprograms when it is defined in /etc/mk.conf
but is not in the environment.
1998-12-06 09:06:45 +00:00
pk f16cf517fe typo. 1998-12-05 21:09:23 +00:00
jwise ca027085f0 Fix spelling of `Churchill' in 3 places 1998-11-20 03:35:31 +00:00
hubertf d5f8b67ebe Add support for decoding of morse code. 1998-11-18 14:22:32 +00:00
hubertf 51755c03b2 fix usage 1998-11-18 09:06:26 +00:00
hubertf a9d35e8322 constify, per PR 6150 by Joseph Myers <jsm28@cam.ac.uk> 1998-11-10 13:43:30 +00:00
hubertf 6d265b3268 constify, per PR 6148 1998-11-10 13:01:31 +00:00
hubertf 30b3ea8d71 make objdir-aware 1998-11-09 15:30:10 +00:00
lukem b569ddabe9 don't install in /usr/share if NOSHARE is defined 1998-09-29 07:33:20 +00:00
frueauf ad506eb7a0 Fix args processing of backgammon and teachgammon, closes pr 5345 by
David Brownlee.
1998-09-15 13:43:34 +00:00
hubertf bd946d241e constify (PR#6151, once more by Joseph Myers <jsm28@cam.ac.uk>) 1998-09-14 09:30:57 +00:00
hubertf 006cc8ac96 return error on errors (PR#6147 by Joseph Myers <jsm28@cam.ac.uk>) 1998-09-14 09:29:08 +00:00
hubertf 4e4187282a constify, as per PR#6136 by Joseph Myers <jsm28@cam.ac.uk> 1998-09-14 09:13:46 +00:00
hubertf 6f55e2e275 remove x bit from save files (PR#6077) 1998-09-13 15:41:34 +00:00
hubertf b0178f6b01 Remove unused function and mark non-returning ones(PR#6076, #6144 by Joseph Myers <jsm28@cam.ac.uk>) 1998-09-13 15:31:07 +00:00
hubertf 1c9494f62b mark non-returning functions (PR#6144 by Joseph Myers <jsm28@cam.ac.uk>) 1998-09-13 15:27:25 +00:00
hubertf 3aca90fd78 fix bug w/ negative numbers, mark non-returning functions (PR#6142+6144 by Joseph Myers <jsm28@cam.ac.uk>) 1998-09-13 15:24:57 +00:00
hubertf ade2d3629c add sanity checks when saving/restoring games (PR#6138 by Joseph Myers <jsm28@cam.ac.uk>) 1998-09-13 15:24:41 +00:00
hubertf 878ef9cb13 check for malloc failures (PR#6136 by Joseph Myers <jsm28@cam.ac.uk>) 1998-09-13 15:24:09 +00:00
hubertf 9e7f2724b9 some cleanups as per PR#6082 by Joseph Myers <jsm28@cam.ac.uk> 1998-09-13 15:23:40 +00:00
hubertf f92ae4adb5 remove unused files (PR#6083 by Joseph Myers <jsm28@cam.ac.uk>) 1998-09-13 15:22:57 +00:00
hubertf dd397c841b remove unused function return values (PR#6079 by Joseph Myers <jsm28@cam.ac.uk>) 1998-09-13 15:21:36 +00:00
hubertf 3f1f74edef Saved games can NOT be restored by executing the save file (PR#6077) 1998-09-13 15:21:05 +00:00
hubertf 0056c879de Replace special handling of \r by using ICRNL (PR#6078 by Joseph Myers <jsm28@cam.ac.uk>) 1998-09-13 15:20:31 +00:00
hubertf 9713f31f7c Remove unused function (PR#6076 by Joseph Myers <jsm28@cam.ac.uk>) 1998-09-13 15:19:35 +00:00
hubertf 5795fc4c70 Make dm ignore TZ; PR#6073 by Joseph Myers <jsm28@cam.ac.uk> 1998-09-13 12:34:43 +00:00
hubertf 4e1357c739 constify, per PR 6041 by Joseph Myers <jsm28@cam.ac.uk> 1998-09-13 00:07:24 +00:00
frueauf 6d6da27a53 Correct attribution as pointed out in pr 6114 by Jim Wise. 1998-09-12 22:49:12 +00:00
wrstuden aaae79a78d Make the helper programs compile right in a cross-compiling environment. 1998-09-12 19:05:48 +00:00
hubertf 4d8c1c95f9 add main() prototype 1998-09-11 14:51:18 +00:00
hubertf 441ff4f749 fix prototype, PR#5867 1998-09-11 14:28:28 +00:00
hubertf 923fd93941 use symbolic constant for open(), PR#5867 1998-09-11 14:26:19 +00:00
hubertf 9a9bb90e33 fix main() prototype, per PR#5867 1998-09-11 14:25:22 +00:00
hubertf eb2507ecb2 fix prototype, per PR#5867 1998-09-11 14:11:57 +00:00
hubertf 3fd99e1631 fix prototypes, per PR#5867 1998-09-11 14:09:27 +00:00
hubertf 0ef663b102 fix prototype of mon_sees(), per PR#5867 1998-09-11 14:07:51 +00:00
hubertf d4741e5a86 be more precise for PI, as per PR5867 1998-09-11 14:07:04 +00:00