Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. =================================================================== RCS file: /ftp/cvs/cvsroot/src/games/monop/prop.c,v retrieving revision 1.11.10.1 retrieving revision 1.12 diff -u -p -r1.11.10.1 -r1.12 --- src/games/monop/prop.c 2008/03/23 00:25:43 1.11.10.1 +++ src/games/monop/prop.c 2008/01/28 06:16:13 1.12 @@ -1,4 +1,4 @@ -/* prop.c,v 1.11 2006/03/19 00:18:47 christos Exp */ +/* $NetBSD: prop.c,v 1.12 2008/01/28 06:16:13 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,13 +34,12 @@ #if 0 static char sccsid[] = "@(#)prop.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("prop.c,v 1.11 2006/03/19 00:18:47 christos Exp"); +__RCSID("$NetBSD: prop.c,v 1.12 2008/01/28 06:16:13 dholland Exp $"); #endif #endif /* not lint */ #include - -#include "monop.h" +#include "monop.ext" static int value(SQUARE *); @@ -65,13 +64,13 @@ void add_list(plr, head, op_sqr) int plr; OWN **head; - int op_sqr; + int op_sqr; { int val; OWN *tp, *last_tp; OWN *op; - op = calloc(1, sizeof (OWN)); + op = (OWN *)calloc(1, sizeof (OWN)); if (op == NULL) errx(1, "out of memory"); op->sqr = &board[op_sqr]; @@ -97,7 +96,10 @@ add_list(plr, head, op_sqr) * This routine deletes property from the list. */ void -del_list(int plr, OWN **head, short op_sqr) +del_list(plr, head, op_sqr) + int plr; + OWN **head; + short op_sqr; { OWN *op, *last_op; @@ -157,14 +159,15 @@ value(sqp) } /* - * This routine accepts bids for the current piece of property. + * This routine accepts bids for the current peice + * of property. */ void bid() { static bool in[MAX_PL]; int i, num_in, cur_max; - char buf[257]; + char buf[80]; int cur_bid; printf("\nSo it goes up for auction. Type your bid after your name\n"); @@ -177,21 +180,17 @@ bid() i = (i + 1) % num_play; if (in[i]) { do { - (void)snprintf(buf, sizeof(buf), "%s: ", - name_list[i]); + (void)sprintf(buf, "%s: ", name_list[i]); cur_bid = get_int(buf); if (cur_bid == 0) { in[i] = FALSE; if (--num_in == 0) break; - } else if (cur_bid <= cur_max) { + } + else if (cur_bid <= cur_max) { printf("You must bid higher than %d " "to stay in\n", cur_max); printf("(bid of 0 drops you out)\n"); - } else if (cur_bid > play[i].money) { - printf("You can't bid more than your cash ($%d)\n", - play[i].money); - cur_bid = -1; } } while (cur_bid != 0 && cur_bid <= cur_max); cur_max = (cur_bid ? cur_bid : cur_max);