diff --git a/src/spells/shipcurse.c b/src/spells/shipcurse.c index 29e4ad8f8..4b0dd9b30 100644 --- a/src/spells/shipcurse.c +++ b/src/spells/shipcurse.c @@ -138,9 +138,11 @@ curse *shipcurse_flyingship(ship * sh, unit * mage, double power, int duration) /* mit C_SHIP_NODRIFT haben wir kein Problem */ curse *c = create_curse(mage, &sh->attribs, ct_flyingship, power, duration, 0.0, 0); - c->data.v = sh; - if (c && c->duration > 0) { - sh->flags |= SF_FLYING; + if (c) { + c->data.v = sh; + if (c->duration > 0) { + sh->flags |= SF_FLYING; + } } return c; }