From 59a1b2e1425834dcc8f7d2b99c931f3c6f6bc28c Mon Sep 17 00:00:00 2001 From: dholland Date: Tue, 19 Jun 2012 05:46:08 +0000 Subject: WARNS=5, and make WARNS=5 the default for src/games. --- hack/hack.shk.c | 7 +++---- hack/hack.shknam.c | 13 ++++++++----- 2 files changed, 11 insertions(+), 9 deletions(-) (limited to 'hack') diff --git a/hack/hack.shk.c b/hack/hack.shk.c index 3c6f962f..7fa85b74 100644 --- a/hack/hack.shk.c +++ b/hack/hack.shk.c @@ -1,4 +1,4 @@ -/* $NetBSD: hack.shk.c,v 1.13 2011/08/07 06:03:45 dholland Exp $ */ +/* $NetBSD: hack.shk.c,v 1.14 2012/06/19 05:46:08 dholland Exp $ */ /* * Copyright (c) 1985, Stichting Centrum voor Wiskunde en Informatica, @@ -63,7 +63,7 @@ #include #ifndef lint -__RCSID("$NetBSD: hack.shk.c,v 1.13 2011/08/07 06:03:45 dholland Exp $"); +__RCSID("$NetBSD: hack.shk.c,v 1.14 2012/06/19 05:46:08 dholland Exp $"); #endif /* not lint */ #include @@ -1103,8 +1103,7 @@ notonl_ok: /* He is digging in the shop. */ void -shopdig(fall) - int fall; +shopdig(int fall) { if (!fall) { if (u.utraptype == TT_PIT) diff --git a/hack/hack.shknam.c b/hack/hack.shknam.c index e503d449..ef17c94e 100644 --- a/hack/hack.shknam.c +++ b/hack/hack.shknam.c @@ -1,4 +1,4 @@ -/* $NetBSD: hack.shknam.c,v 1.7 2009/08/12 07:28:41 dholland Exp $ */ +/* $NetBSD: hack.shknam.c,v 1.8 2012/06/19 05:46:08 dholland Exp $ */ /* * Copyright (c) 1985, Stichting Centrum voor Wiskunde en Informatica, @@ -63,7 +63,7 @@ #include #ifndef lint -__RCSID("$NetBSD: hack.shknam.c,v 1.7 2009/08/12 07:28:41 dholland Exp $"); +__RCSID("$NetBSD: hack.shknam.c,v 1.8 2012/06/19 05:46:08 dholland Exp $"); #endif /* not lint */ #include "hack.h" @@ -206,13 +206,16 @@ static const struct shk_nx { }; void -findname(nampt, let) - char *nampt; - char let; +findname(char *nampt, int let_i) { const struct shk_nx *p = shk_nx; const char *const *q; int i; + char let; + + /* truncate to "char" width */ + let = let_i; + while (p->x && p->x != let) p++; q = p->xn; -- cgit v1.2.3-56-ge451