Fix initialization of new elements in plane, land and nuke tables
ef_init_srv() neglected to set struct empfile callback oninit. This
made unit_carrier_change() crash or oops on freshly initialized
planes, land units and nukes, i.e. when build used an uid that hadn't
been used before. Oops recovery worked.
Broken in commit 64a53c90
, v4.3.17.
This commit is contained in:
parent
62843e166c
commit
f180712625
1 changed files with 1 additions and 0 deletions
|
@ -68,6 +68,7 @@ ef_init_srv(void)
|
|||
unsigned i;
|
||||
|
||||
for (i = 0; i < sizeof(fileinit) / sizeof(fileinit[0]); i++) {
|
||||
empfile[fileinit[i].ef_type].oninit = fileinit[i].oninit;
|
||||
empfile[fileinit[i].ef_type].postread = fileinit[i].postread;
|
||||
empfile[fileinit[i].ef_type].prewrite = fileinit[i].prewrite;
|
||||
empfile[fileinit[i].ef_type].onresize = fileinit[i].onresize;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue