diff options
author | rubidium <rubidium@openttd.org> | 2010-03-12 19:18:26 +0000 |
---|---|---|
committer | rubidium <rubidium@openttd.org> | 2010-03-12 19:18:26 +0000 |
commit | 0903463824538dcec8a19fb3f5c4a6f1bfa2860a (patch) | |
tree | 3e1ed0b97a007e16750880e520dc81429df86db4 /src | |
parent | c7821df97143609137b638801264113bd44c2f55 (diff) | |
download | openttd-0903463824538dcec8a19fb3f5c4a6f1bfa2860a.tar.xz |
(svn r19391) -Fix (r19255): shuffling around GRFIdentifier in GRFConfig caused gamelog to log the wrong data which could cause crashes later on when that data is queried
Diffstat (limited to 'src')
-rw-r--r-- | src/gamelog.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/gamelog.cpp b/src/gamelog.cpp index 83d1ba112..c0325fd2a 100644 --- a/src/gamelog.cpp +++ b/src/gamelog.cpp @@ -543,7 +543,7 @@ void GamelogGRFAdd(const GRFConfig *newg) LoggedChange *lc = GamelogChange(GLCT_GRFADD); if (lc == NULL) return; - memcpy(&lc->grfadd, newg, sizeof(GRFIdentifier)); + lc->grfadd = newg->ident; } /** Logs loading compatible GRF @@ -557,7 +557,7 @@ void GamelogGRFCompatible(const GRFIdentifier *newg) LoggedChange *lc = GamelogChange(GLCT_GRFCOMPAT); if (lc == NULL) return; - memcpy(&lc->grfcompat, newg, sizeof(GRFIdentifier)); + lc->grfcompat = *newg; } /** Logs changing GRF order |