forked from github/server
CID 22545: Leak of memory or pointers to system resources
github issue #335 volcano destruction was not causing a resuction in wages etc., because we forgot to add the attribute to the region.
This commit is contained in:
parent
c9f886078b
commit
4d1f2327fe
1 changed files with 2 additions and 2 deletions
|
@ -580,8 +580,8 @@ volcano_destruction(region * volcano, region * r, const char *damage)
|
|||
rsettrees(r, 0, 0);
|
||||
|
||||
a = a_find(r->attribs, &at_reduceproduction);
|
||||
if (!a) {
|
||||
a = make_reduceproduction(percent, time);
|
||||
if (a) {
|
||||
a = a_add(&r->attribs, make_reduceproduction(percent, time));
|
||||
}
|
||||
else {
|
||||
/* Produktion vierteln ... */
|
||||
|
|
Loading…
Reference in a new issue