diff --git a/src/common/kernel/build.c b/src/common/kernel/build.c index 45ca7cfa8..6d92468ac 100644 --- a/src/common/kernel/build.c +++ b/src/common/kernel/build.c @@ -1,6 +1,6 @@ /* vi: set ts=2: * - * $Id: build.c,v 1.4 2001/02/04 08:47:39 enno Exp $ + * $Id: build.c,v 1.5 2001/02/04 08:52:24 enno Exp $ * Eressea PB(E)M host Copyright (C) 1998-2000 * Christian Schlittchen (corwin@amber.kn-bremen.de) * Katja Zedel (katze@felidae.kn-bremen.de) @@ -161,7 +161,7 @@ struct building * getbuilding(const struct region * r) { building * b = findbuilding(getid()); - if (r!=b->region) return NULL; + if (b==NULL || r!=b->region) return NULL; return b; }