summaryrefslogtreecommitdiff
path: root/src/station_cmd.cpp
diff options
context:
space:
mode:
authorKUDr <kudr@openttd.org>2007-01-11 17:29:39 +0000
committerKUDr <kudr@openttd.org>2007-01-11 17:29:39 +0000
commit33be1ecfb1a9056b027d50d7b558cff87c5b744d (patch)
treed644a3831ca0947198b191fa3e4e8973d3a9786e /src/station_cmd.cpp
parent91ff74641060445dc1647bbf05baeb03b45c3099 (diff)
downloadopenttd-33be1ecfb1a9056b027d50d7b558cff87c5b744d.tar.xz
(svn r8066) - Codechange: MallocT(), CallocT(), ReallocT() now return the pointer to allocated memory instead of modifying the pointer given as parameter
Diffstat (limited to 'src/station_cmd.cpp')
-rw-r--r--src/station_cmd.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/station_cmd.cpp b/src/station_cmd.cpp
index e94da91da..ea89c45f9 100644
--- a/src/station_cmd.cpp
+++ b/src/station_cmd.cpp
@@ -3065,7 +3065,7 @@ static void SaveLoad_STNS(Station *st)
if (st->num_specs != 0) {
/* Allocate speclist memory when loading a game */
- if (st->speclist == NULL) CallocT(&st->speclist, st->num_specs);
+ if (st->speclist == NULL) st->speclist = CallocT<StationSpecList>(st->num_specs);
for (i = 0; i < st->num_specs; i++) SlObject(&st->speclist[i], _station_speclist_desc);
}
}