diff --git a/src/newgrf.cpp b/src/newgrf.cpp index a015fe5ade..c0f59b92e2 100644 --- a/src/newgrf.cpp +++ b/src/newgrf.cpp @@ -6954,7 +6954,7 @@ static void GRFSound(ByteReader *buf) if (type != 0xFF) { grfmsg(1, "GRFSound: Unexpected RealSprite found, skipping"); FioSkipBytes(7); - SkipSpriteData(type, num - 8); + SkipSpriteData(type, len - 8); continue; }