- spelling error in message fail_tooheavy

- crashed when message couldn't be created
This commit is contained in:
Enno Rehling 2004-05-26 06:24:22 +00:00
parent 16f28a3d99
commit 6298a3a165
5 changed files with 7 additions and 7 deletions

View File

@ -17,8 +17,8 @@ if ! $(CCACHE_DIR) {
if $(PROFILE) = 1 {
Echo Compiling with profiler ;
CCFLAGS += -pg ;
LINKFLAGS += -pg ;
CCFLAGS += -pg -g ;
LINKFLAGS += -pg -g ;
}
CCFLAGS += -Wall ;

View File

@ -68,7 +68,7 @@ extern const struct messageclass * mc_find(const char * name);
/* convenience, deprecated */
extern struct message * new_message(struct faction * receiver, const char * signature, ...);
#define ADDMSG(msgs, mcreate) { message * m = mcreate; assert (m->refcount==1); if (m) { add_message(msgs, m); msg_release(m); } }
#define ADDMSG(msgs, mcreate) { message * m = mcreate; if (m) { assert(m->refcount>=1); add_message(msgs, m); msg_release(m); } }
#ifdef __cplusplus
}

View File

@ -938,7 +938,7 @@ seen_done(void)
seen_region *
find_seen(const region * r)
{
int index = abs((r->x & 0xffff) + ((r->y) << 16)) % MAXSEEHASH;
int index = ((int)r) % MAXSEEHASH;
seen_region * find=seehash[index];
while (find) {
if (find->r==r) return find;
@ -952,7 +952,7 @@ add_seen(const struct region * r, unsigned char mode, boolean dis)
{
seen_region * find = find_seen(r);
if (find==NULL) {
int index = abs((r->x & 0xffff) + ((r->y) << 16)) % MAXSEEHASH;
int index = ((int)r) % MAXSEEHASH;
if (!reuse) reuse = (seen_region*)calloc(1, sizeof(struct seen_region));
find = reuse;
reuse = reuse->nextHash;

View File

@ -968,7 +968,7 @@ fix_astralplane(void)
if (ra->units!=NULL) {
add_regionlist(&rlist, ra);
}
log_printf("protecting firewall in %s by blocking astral space in %s.\n", regionname(r), regionname(ra));
log_printf("protecting firewall in %s by blocking astral space in %s.\n", regionname(r, NULL), regionname(ra, NULL));
terraform(ra, T_ASTRALB);
}
while (rlist!=NULL) {

View File

@ -5968,7 +5968,7 @@
<text locale="en">"$unit($unit) disappears."</text>
</message>
<message name="fail_toheavy" section="errors">
<message name="fail_tooheavy" section="errors">
<type>
<arg name="command" type="order"/>
<arg name="region" type="region"/>