From b0895ad7cd2265678d80162d1762c73b5ee898c6 Mon Sep 17 00:00:00 2001 From: Enno Rehling Date: Sun, 24 Mar 2002 09:57:18 +0000 Subject: [PATCH] * variablen-deklarationen sind in C nur am anfang eines blocks erlaubt --- src/common/kernel/faction.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/common/kernel/faction.c b/src/common/kernel/faction.c index a0b5eab10..d5d60edc9 100644 --- a/src/common/kernel/faction.c +++ b/src/common/kernel/faction.c @@ -86,12 +86,12 @@ addplayer(region *r, const char *email, const struct race * frace, const locale { int i; unit *u; + faction *f; - assert(frace != new_race[RC_ORC]); + assert(frace != new_race[RC_ORC]); + f = calloc(sizeof(faction), 1); - faction *f = (faction *) calloc(1, sizeof(faction)); - - set_string(&f->email, email); + set_string(&f->email, email); for (i = 0; i < 6; i++) buf[i] = (char) (97 + rand() % 26); buf[i] = 0; set_string(&f->passw, buf);