mirror of
https://github.com/vattam/BSDGames.git
synced 2025-12-21 03:14:50 +00:00
* New upstream release, whivh includes hack, back fron bsdgames-nonfree.
* Conflict and replace with old versions of bsdgames-nonfree that include
hack.
* Add hack to package description and menu file.
* Add in hack's two READ_ME files to binay package.
* Patched hack config.h as it is patched in bsdgames-nonfree.
* Unlike bsdgames-nonfree, put the help, hh, rumors, and data files in
/usr/share/games/bsdgames/hack, as the patched config.h makes it look
there.
* postinst moves over hack state files to new directory
* Patched phantasia to use strerror and not segfault if it cannot open the
var files. Closes: #187251 (patch sent upstream)
git-svn-id: file:///srv/svn/joey/bsdgames-trunk@5206 a4a2c43b-8ac3-0310-8836-e0e880c912e2
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
/* $NetBSD: extern.c,v 1.6 1999/09/17 20:45:48 jsm Exp $ */
|
||||
/* $NetBSD: extern.c,v 1.7 2002/01/20 00:42:51 jsm Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1983, 1993
|
||||
@@ -38,7 +38,7 @@
|
||||
#if 0
|
||||
static char sccsid[] = "@(#)extern.c 8.1 (Berkeley) 5/31/93";
|
||||
#else
|
||||
__RCSID("$NetBSD: extern.c,v 1.6 1999/09/17 20:45:48 jsm Exp $");
|
||||
__RCSID("$NetBSD: extern.c,v 1.7 2002/01/20 00:42:51 jsm Exp $");
|
||||
#endif
|
||||
#endif /* not lint */
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* $NetBSD: getword.c,v 1.6 1999/09/08 21:57:17 jsm Exp $ */
|
||||
/* $NetBSD: getword.c,v 1.7 2002/01/20 00:42:51 jsm Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1983, 1993
|
||||
@@ -38,7 +38,7 @@
|
||||
#if 0
|
||||
static char sccsid[] = "@(#)getword.c 8.1 (Berkeley) 5/31/93";
|
||||
#else
|
||||
__RCSID("$NetBSD: getword.c,v 1.6 1999/09/08 21:57:17 jsm Exp $");
|
||||
__RCSID("$NetBSD: getword.c,v 1.7 2002/01/20 00:42:51 jsm Exp $");
|
||||
#endif
|
||||
#endif /* not lint */
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
.\" $NetBSD: hangman.6,v 1.7 1999/09/17 20:45:49 jsm Exp $
|
||||
.\" $NetBSD: hangman.6,v 1.11 2003/02/25 10:34:46 wiz Exp $
|
||||
.\"
|
||||
.\" Copyright (c) 1983, 1993
|
||||
.\" The Regents of the University of California. All rights reserved.
|
||||
@@ -38,14 +38,14 @@
|
||||
.Os
|
||||
.Sh NAME
|
||||
.Nm hangman
|
||||
.Nd Computer version of the game hangman
|
||||
.Nd computer version of the game hangman
|
||||
.Sh SYNOPSIS
|
||||
.Nm
|
||||
.Op Fl d Ar wordlist
|
||||
.Op Fl m Ar minlen
|
||||
.Sh DESCRIPTION
|
||||
In
|
||||
.Nm "" ,
|
||||
.Nm ,
|
||||
the computer picks a word from the on-line word list
|
||||
and you must try to guess it.
|
||||
The computer keeps track of which letters have been guessed
|
||||
@@ -57,12 +57,13 @@ Use the specified
|
||||
.Ar wordlist
|
||||
instead of the default one named below.
|
||||
.It Fl m
|
||||
Set the minimum word length to use. The default is 6 letters.
|
||||
Set the minimum word length to use.
|
||||
The default is 6 letters.
|
||||
.El
|
||||
.Sh FILES
|
||||
.Bl -tag -width @hangman_wordsfile@ -compact
|
||||
.It Pa @hangman_wordsfile@
|
||||
On-line word list
|
||||
.El
|
||||
.Sh AUTHOR
|
||||
Ken Arnold
|
||||
.Sh AUTHORS
|
||||
.An Ken Arnold
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* $NetBSD: hangman.h,v 1.10 1999/09/17 20:45:49 jsm Exp $ */
|
||||
/* $NetBSD: hangman.h,v 1.11 2002/01/20 00:42:51 jsm Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1983, 1993
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* $NetBSD: main.c,v 1.9 2000/05/08 07:56:04 mycroft Exp $ */
|
||||
/* $NetBSD: main.c,v 1.10 2002/01/20 00:42:51 jsm Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1983, 1993
|
||||
@@ -43,10 +43,11 @@ __COPYRIGHT("@(#) Copyright (c) 1983, 1993\n\
|
||||
#if 0
|
||||
static char sccsid[] = "@(#)main.c 8.1 (Berkeley) 5/31/93";
|
||||
#else
|
||||
__RCSID("$NetBSD: main.c,v 1.9 2000/05/08 07:56:04 mycroft Exp $");
|
||||
__RCSID("$NetBSD: main.c,v 1.10 2002/01/20 00:42:51 jsm Exp $");
|
||||
#endif
|
||||
#endif /* not lint */
|
||||
|
||||
#include <err.h>
|
||||
#include "hangman.h"
|
||||
|
||||
/*
|
||||
@@ -62,17 +63,15 @@ main(argc, argv)
|
||||
/* Revoke setgid privileges */
|
||||
setregid(getgid(), getgid());
|
||||
|
||||
while ((ch = getopt(argc, argv, "m:d:")) != -1) {
|
||||
while ((ch = getopt(argc, argv, "d:m:")) != -1) {
|
||||
switch (ch) {
|
||||
case 'd':
|
||||
Dict_name = optarg;
|
||||
break;
|
||||
case 'm':
|
||||
Minlen = atoi(optarg);
|
||||
if (Minlen < 2) {
|
||||
fprintf(stderr, "minlen too short\n");
|
||||
exit(1);
|
||||
}
|
||||
if (Minlen < 2)
|
||||
errx(1, "minimum word length too short");
|
||||
break;
|
||||
case '?':
|
||||
default:
|
||||
|
||||
Reference in New Issue
Block a user