diff --git a/src/common/kernel/movement.c b/src/common/kernel/movement.c index e56e5bfe4..c8b59800b 100644 --- a/src/common/kernel/movement.c +++ b/src/common/kernel/movement.c @@ -45,6 +45,7 @@ /* util includes */ #include +#include #include #include @@ -550,6 +551,17 @@ move_ship(ship * sh, region * from, region * to, region_list * route) } if (*iunit==u) iunit=&u->next; } + +#ifndef NDEBUG + if (rterrain(sh->region)!=T_OCEAN) { + region * rcoast = rconnect(sh->region, sh->coast); + if (rterrain(rcoast)!=T_OCEAN) { + log_error(("ship %s sailed into a coast with no ocean neighbours.\n", + shipid(sh))); + } + } +#endif + return sh; } diff --git a/src/common/util/translation.c b/src/common/util/translation.c index fbaa61512..5539b5c0d 100644 --- a/src/common/util/translation.c +++ b/src/common/util/translation.c @@ -335,7 +335,7 @@ parse(opstack ** stack, const char* inn, const void * userdata) } const char * -translate(const char* format, const void * userdata, const char* vars, const void* args[]) +translate(const char* format, const void * userdata, const char* vars, void* args[]) { int i = 0; const char *ic = vars; diff --git a/src/common/util/translation.h b/src/common/util/translation.h index 18cca01b5..916df2944 100644 --- a/src/common/util/translation.h +++ b/src/common/util/translation.h @@ -25,7 +25,7 @@ extern void opstack_push(struct opstack ** stack, void * data); extern void translation_init(void); extern void translation_done(void); extern const char * translate_va(const char* format, const void * userdata, const char* vars, ...); -extern const char * translate(const char* format, const void * userdata, const char* vars, const void* args[]); +extern const char * translate(const char* format, const void * userdata, const char* vars, void* args[]); /* eval_x functions */ typedef void (*evalfun)(struct opstack ** stack, const void *);