No special formatting used for the movie name for now, following
discussion on tech-userlevel suggesting that at present there's
nothing really appropriate.
macro). Add new fwrite_be_offt() function which writes out a big-endian
64bit number regards of the size of off_t on the host machine.
Also fix ``bug'' in previous - even though the off_t pointers were
stored big-endian, the individual card lenghs were in host-order. The
cards.pck files are now identical when make on a big- or little-endian
machine.
Now builds a correct cards.pck file on non-NetBSD machines as well
- tested on Ultrix and Solaris (but Solaris needs -lsocket to get
htonl()).
- replaiced with local die() and dieperror() routines). Use ANSI
prototypes (no dependance on the __P() macro). Add new fwrite_be_offt()
function which writes out a big-endian 64bit number regards of the size
of off_t on the host machine. Remove unused unctrl() function.
Now builds correct fortune .dat files on non-NetBSD machines as well
- tested on Ultrix and Solaris (but Solaris needs -lsocket to get
htonl()).
every letter, add appropriate index lines. Problem reported by Mike
Castle <dalgoda@ix.netcom.com> against the Linux port of the NetBSD games
collection.
up somewhat. Change time specification format to similar to that used
by date(1) - taking a command line argument in seconds since the Epoch
is silly. Date parsing based on code from date(1).
Based on work by Paul Janzen for 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.
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).
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).
Some such changes were previously covered in PRs bin/6041, bin/6146,
bin/6148, bin/6150, bin/6151, bin/6580, bin/6660, bin/7993, bin/7994,
bin/8039, bin/8057 and bin/8093.
of the card decks file, just write out the number of cards for each
deck. Also use "off_t" for offsets into the file (that are stored after
the number of cards) instead of "long".
/usr/share/games/cards.pck is now MI.
the stored the same regardess of the byte order of the generating
host.
Note in the strfile(8) man page that all fields are big-endian, not
in network byte order.
"make build" should now work as a non-root user (tested on Alpha).
mtree spits out lots of warnings during "make distrib-dirs", but
these are non-fatal.
to stderr.
The existing error message ("I don't know what xxx means") is
unchanged, as it is stylisticly in keeping with the light-hearted
nature of the program, and is also more likely to be accurate than the
"no such acronym" error message proposed in 8201.
simplifying the code and improving its portability. It also adds a
delay option from OpenBSD, to allow reasonable speed display on fast
terminals, adds use of const, and fixes signal handling and use of
errx() where appropriate.
Patch supplied in PR 6661 by Joseph Myers <jsm28@cam.ac.uk>.
significantly simplifying the code and improving its portability. It
also adds a delay option from OpenBSD to make the display go at a
useful speed on fast terminals, and fixes signal handling to make it
reliable.
Patch supplied by Joseph Myers <jsm28@cam.ac.uk> in PR 6659.
objects in its header file, and to add corresponding definitions to
init.c accordingly. (See the C standard - relying on linker commons
where there are multiple uninitialised declarations of an object in
the program traditionally works on Unix, but is not standard C.)
The patch also removes a bit-rotten code fragment under #ifdef
OLDSTUFF.
Patch submitted in PR 8105 by Joseph Myers <jsm28@cam.ac.uk>
Morse code standards to the bcd(6) manpage (which also serves as the
manpages ppt(6) and morse(6)).
(The only one of these standards I have read is the ECMA-10 paper tape
standard, which is also probably the least readily available, since
ECMA don't supply copies of obsolete standards, though they will
supply printed copies of any or all of their current standards at no
charge.)
Patch submitted in PR 8102 by Joseph Myers <jsm28@cam.ac.uk>
unsigned char rather than char for values that end up passed to
isascii() and also used as array indices.
Patch submitted by Joseph Myers <jsm28@cam.ac.uk> in PR 8093.
with variations in EINTR behaviour, but the optimisation of using the
BSD version where the SYSV version isn't needed is insignificant.
This patch therefore simplifies the code by making there be just one
version, a more paranoid (about EOF when errno is already EINTR)
version of the SYSV code. Since the BSD/SYSV defines are mainly used
to control whether BSD timers are used, this helps where BSD timers
but SYSV EINTR handling are wanted.
Patch supplied in PR 8091 by Joseph Myers <jsm28@cam.ac.uk>
allowing the user to choose the name of the save file and specify it
on the command line when restoring. It also eliminates a buffer
overrun in determining the path to the save file, and any particular
arbitrary limit on the name length. In the name of a tidier home
directory, the default name is changed from "Bstar" to ".Bstar".
Patch supplied in PR 8085 by Joseph Myers <jsm28@cam.ac.uk>
Minor modification (s/startup/filename/ in initialize()) by me.
backgammon(6). The use of write(2) for the message may seem odd, but
is used in another place in this game. (Actually, a lot of
backgammon(6) could do with being substantially cleaned up.)
Patch submitted in PR 8080 by Joseph Myers <jsm28@cam.ac.uk>
being defined more than once incorrectly checks for `height' having
been previously defined instead.
Patch submitted in PR 8038 by Joseph Myers <jsm28@cam.ac.uk>
open the score file at the start and then drop all setgid privileges
while keeping a (close-on-exec) file descriptor open to it. In order
to allow this the static data files have to be made world readable.
In addition a potential buffer overrun with corrupted score files is
avoided by more careful use of scanf (note that SCORE_SCANF_FMT is
defined alongside the definition of the relevant structure).
Submitted in PR 8015 by Joseph Myers <jsm28@cam.ac.uk>