games/taipan: fix out of bounds array subscript
taipan.c:2709:7: warning: array index 4 is past the end of the array (which contains 4 elements) [-Warray-bounds] PR: 206771 Submitted by: Dave Walton <dw-fbsd@digger.net> Submitted by: c.brinkhaus@t-online.de
This commit is contained in:
parent
bd3e639c96
commit
e12125add7
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=412884
2 changed files with 14 additions and 4 deletions
|
@ -3,7 +3,7 @@
|
|||
|
||||
PORTNAME= taipan
|
||||
PORTVERSION= 0.9
|
||||
PORTREVISION= 1
|
||||
PORTREVISION= 2
|
||||
CATEGORIES= games
|
||||
MASTER_SITES= SUNSITE/games/textrpg
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
--- taipan.c.orig Fri Mar 15 15:05:41 2002
|
||||
+++ taipan.c Fri Mar 15 15:08:30 2002
|
||||
@@ -2572,7 +2572,7 @@
|
||||
--- taipan.c.orig 2001-12-31 16:09:20 UTC
|
||||
+++ taipan.c
|
||||
@@ -2572,7 +2572,7 @@ void mchenry(void)
|
||||
amount = get_num(9);
|
||||
if (amount == -1)
|
||||
{
|
||||
|
@ -9,3 +9,13 @@
|
|||
}
|
||||
if (amount <= cash)
|
||||
{
|
||||
@@ -2705,8 +2705,8 @@ void final_stats(void)
|
||||
bank = 0;
|
||||
hkw_[0] = 0;
|
||||
hkw_[1] = 0;
|
||||
+ hkw_[2] = 0;
|
||||
hkw_[3] = 0;
|
||||
- hkw_[4] = 0;
|
||||
hold_[0] = 0;
|
||||
hold_[1] = 0;
|
||||
hold_[2] = 0;
|
||||
|
|
Loading…
Reference in a new issue