diff --git a/src/spells/flyingship.c b/src/spells/flyingship.c index 7751451ed..da57ddd93 100644 --- a/src/spells/flyingship.c +++ b/src/spells/flyingship.c @@ -154,9 +154,11 @@ static curse *shipcurse_flyingship(ship * sh, unit * mage, double power, int dur /* 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; }