From 15971fdb984334ba410e97675ef78028fb82dd3d Mon Sep 17 00:00:00 2001 From: Enno Rehling Date: Tue, 3 Jun 2008 10:16:55 +0000 Subject: [PATCH] fixing find_key. ouch! --- src/common/attributes/key.c | 4 ++-- src/common/kernel/binarystore.c | 2 +- src/res/eressea/strings.xml | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/common/attributes/key.c b/src/common/attributes/key.c index b088bb6eb..62180f279 100644 --- a/src/common/attributes/key.c +++ b/src/common/attributes/key.c @@ -47,11 +47,11 @@ make_key(int key) attrib * find_key(attrib * alist, int key) { - attrib * a = a_find(alist, &at_key); + attrib * a = a_find(alist, &at_key); while (a && a->type==&at_key && a->data.i != key) { a = a->next; } - return a; + return (a && a->type==&at_key)?a:NULL; } void diff --git a/src/common/kernel/binarystore.c b/src/common/kernel/binarystore.c index 78961dc4d..8be4184f1 100644 --- a/src/common/kernel/binarystore.c +++ b/src/common/kernel/binarystore.c @@ -151,7 +151,7 @@ bin_w_str(struct storage * store, const char * tok) return result; } -#define FIX_INVALID_CHARS +#define FIX_INVALID_CHARS /* required for data pre-574 */ static char * bin_r_str(struct storage * store) { diff --git a/src/res/eressea/strings.xml b/src/res/eressea/strings.xml index 62e24ce38..d903cc654 100644 --- a/src/res/eressea/strings.xml +++ b/src/res/eressea/strings.xml @@ -368,7 +368,7 @@ - Adamantaxe + Adamantaxt adamantium axe