mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2025-06-20 20:19:35 +01:00
(svn r26067) -Fix: possible NULL dereference when getting NewGRF version
This commit is contained in:
parent
d18852170b
commit
c035a9531b
@ -6578,7 +6578,7 @@ static void ParamSet(ByteReader *buf)
|
||||
/* Disable the read GRF if it is a static NewGRF. */
|
||||
DisableStaticNewGRFInfluencingNonStaticNewGRFs(c);
|
||||
src1 = 0;
|
||||
} else if (file == NULL || (c != NULL && c->status == GCS_DISABLED)) {
|
||||
} else if (file == NULL || c == NULL || c->status == GCS_DISABLED) {
|
||||
src1 = 0;
|
||||
} else if (src1 == 0xFE) {
|
||||
src1 = c->version;
|
||||
|
Loading…
Reference in New Issue
Block a user