summaryrefslogtreecommitdiff
path: root/newgrf.c
diff options
context:
space:
mode:
authorpeter1138 <peter1138@openttd.org>2006-12-08 19:35:13 +0000
committerpeter1138 <peter1138@openttd.org>2006-12-08 19:35:13 +0000
commitf64a3d180b21f6c18f217d23be7ebf0cad1514f1 (patch)
tree49dc17e3944dad962f7054916b253e8052136a28 /newgrf.c
parent08e02d574f51c77d6a73af85a66fad066358ac77 (diff)
downloadopenttd-f64a3d180b21f6c18f217d23be7ebf0cad1514f1.tar.xz
(svn r7437) -Fix (r4583): incorrect minimum size check in some cases for VarAction2
Diffstat (limited to 'newgrf.c')
-rw-r--r--newgrf.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/newgrf.c b/newgrf.c
index 3eb372827..308e925cc 100644
--- a/newgrf.c
+++ b/newgrf.c
@@ -1624,7 +1624,7 @@ static void NewSpriteGroup(byte *buf, int len)
case 2: group->g.determ.size = DSG_SIZE_DWORD; varsize = 4; break;
}
- check_length(bufend - buf, 2 + (varsize * 3) + 2, "NewSpriteGroup (Deterministic) (2)");
+ check_length(bufend - buf, 5 + varsize, "NewSpriteGroup (Deterministic) (2)");
/* Loop through the var adjusts. Unfortunately we don't know how many we have
* from the outset, so we shall have to keep reallocing. */