summaryrefslogtreecommitdiff
path: root/games/mille
AgeCommit message (Collapse)Author
2023-10-10Use vw_printw() and fix a format print warning.Theo Buehler
2022-02-18Avoid gendered language in man pages when not referring to a specificJonathan Gray
person. Rewrite or use singular they. ok thfr@ sthen@ daniel@ ian@ job@ kmos@ jcs@ ratchov@ phessler@ and others I'm likely missing on an earlier version. feedback tj@, feedback and ok jmc@
2021-10-23if both stdout and stderr are redirected to a non-tty, pledge(2) will killRicardo Mestre
ncurses applications, e.g.: /usr/games/worms 2>&1 | cat solve this by only calling pledge(2) after initscr(3) is set and done, or whatever function that calls it. since pledge(2) is called later now the promises might be reduced, but this a diff for another day. found by naddy@ almost a year ago, discussed with him deraadt@ and tb@ ok tb@
2019-06-28When system calls indicate an error they return -1, not some arbitraryTheo de Raadt
value < 0. errno is only updated in this case. Change all (most?) callers of syscalls to follow this better, and let's see if this strictness helps us in the future.
2016-09-11Callers of time(3) should #include <time.h>.Theo Buehler
ok deraadt
2016-01-08ANSIfy mille(6)mestre
OK tb@
2016-01-08Headers cleanup and also the following:mestre
mille.h: #define CTRL locally, which is used by move.c and misc.c, to avoid including termios.h or sys/ttydefaults.h where it's actually defined varpush.c: Change _PATH_DEVNULL to "/dev/null" since other systems may not have it defined but also avoids including <paths.h> Included a few sugestions from tb@ who also gave his OK
2016-01-07Some basic code maintenance in games/tb
- in main() replace exit with return - drop some /* NOTREACHED */ lint comments along the way. - make more use of standard CFLAGS, esp. -Wimplicit-function-declaration - add and sort some headers when needed - add straightforward pledges to some programs used at compile time discussed with and ok mestre@
2016-01-03About 13 years ago when the idiom srandom(time()), and sometimesmestre
srandom(time()+getpid()), was changed by srandomdev(), but #include <time.h> lived up until this day so remove it. Additionally, earlier than that, 18 years ago, random(6) was one of the first consumers of arc4random(3) family, and was pulling it from dev/rndvar.h but these days we pull it from stdlib.h, which is already done, so while here remove dev/rndvar.h also. "seems comprehensive to me" deraadt@ and OK tb@
2015-12-26Set as __dead a few more functions, that don't return, on games/mestre
With precious tip, help and also OK from tb@
2015-11-30The usual deal for a curses game with the possibility of saving a game:tb
pledge "stdio rpath wpath cpath tty"
2015-11-11creat() -> open equiv; from Frederic NowakTheo de Raadt
2015-11-04replace setbuf with setvbuf, from Frederic NowakTed Unangst
2015-10-24Cast ctype functions' arguments to unsigned char.mmcc
ok guenther@
2015-01-19normalize formattingTheo de Raadt
2014-11-16Eliminate pointless use of <sys/param.h>, <sys/file.h>, <sys/sockio.h>,Philip Guenther
and <sys/ttydefaults.h> Replace MAXPATHLEN with PATH_MAX and MAXLOGNAME with LOGIN_NAME_MAX Pull in <limits.h> where needed Prefer sizeof(var) over MAXFOO or FOO_MAX ok deraadt@
2014-11-03use knuth shuffle for better distribution of permutationsTed Unangst
2014-09-08obvious cases of missing .An;Ingo Schwarze
found with the new mandoc(1) MANDOCERR_AN_MISSING warning; no text changes
2013-08-29replace srandomdev()+random() with the arc4random*() familyChristian Weisgerber
tweaks and ok millert@, ok deraadt@
2011-09-03make -column lists pretty again;Jason McIntyre
specifically, rewrite them to permit some markup in the column headers, and use "Ta" instead of literal tabs; mandoc does not currently match groff 100%, but a mandoc fix may be some time off, and we've gone enough releases with poorly formatting column lists. in some cases i have rewritten the lists as -tag, where -column made little sense.
2009-12-10fix potential bugs spotted by parfaitBob Beck
ok millert@ pjanzen@
2009-10-28rcsid[] and sccsid[] and copyright[] are essentially unmaintained (andTheo de Raadt
unmaintainable). these days, people use source. these id's do not provide any benefit, and do hurt the small install media (the 33,000 line diff is essentially mechanical) ok with the idea millert, ok dms
2009-10-17synchronize synopsis and usage.Igor Sobrado
2007-05-31convert to new .Dd format;Jason McIntyre
2006-12-24fix program name in usage, use __prognameMartin Reindl
2006-10-31usage information goes to stderrMartin Reindl
2006-03-27assorted fixes mostly from coverity via netbsd via jasper adriaanse via techTed Unangst
2003-06-03Remove the advertising clause in the UCB license which BerkeleyTodd C. Miller
rescinded 22 July 1999. Proofed by myself and Theo.
2003-04-23some typos, and clarification of game rules;Jason McIntyre
help, suggestions and ok pjanzen@
2003-04-062451 lines of strdup/sprintf/strcpy whacking. mostly ok'd by pjanzenTheo de Raadt
already, but he may have later changes to make still.
2003-03-06broken .Xr's;Jason McIntyre
typos, rather than dead references ok deraadt@
2002-12-06Replace things like srandom(time(NULL)) with srandomdev(3). random(3)Todd C. Miller
good enough for games but we should at least use a decent seed. pjanzen@ OK
2002-05-31crmode -> cbreakPaul Janzen
2002-05-31No dm -> no need to revoke setegid.Paul Janzen
2002-05-23The troll strikes.. The troll strikes.. The dungeon master ↵Theo de Raadt
dies.distrib/sets/lists
2002-02-19We live in an ANSI C world. Remove lots of gratuitous #ifdef __STDC__ cruft.Todd C. Miller
2002-02-17Manual cleanup of remaining userland __P use (excluding packages maintained ↵Todd C. Miller
outside the tree)
2002-02-16Part one of userland __P removal. Done with a simple regexp with some minor ↵Todd C. Miller
hand editing to make comments line up correctly. Another pass is forthcoming that handles the cases that could not be done automatically.
2001-11-17section consistency: AUTHOR -> AUTHORS, even if only one listed;Paul Janzen
mpech@prosoft.org.lv
2001-09-03Tidying, some from NetBSD.Paul Janzen
2001-08-18FormattingPaul Janzen
2001-03-08whack exit(-#)Theo de Raadt
2000-08-05Remove a little redundant and slightly wrong codePaul Janzen
2000-07-23Die more cleanly if stdin can't be read from.Paul Janzen
2000-04-07Remove unused ifdef missed previouslyPaul Janzen
1999-11-25Fix an obscure bug involving misidentified coup fourres.Paul Janzen
1999-09-30better use of cursesPaul Janzen
1999-09-30Disallow "Go" after "Right of Way" and change Battle Pile status to "Go" whenPaul Janzen
appropriate when playing "Right of Way".
1999-09-25Tidying and minor changes from or based on jsm28@cam.ac.uk's work for thePaul Janzen
Linux bsd-games package and NetBSD. Mainly using 'const'.
1999-07-09- remove all trailing whitespaceAaron Campbell
* except when it is escaped with a `\' at the end of the line - fix remaining .Nm usage as well - this is from a patch I received from kwesterback@home.com, who has been working on some scripts for fixing formatting errors in mdoc'd man pages Ok, so there could be a cost/benefit debate with this commit, but since I have the patch we might as well commit it...