--- deliantra/server/common/utils.C 2008/01/25 18:09:23 1.70 +++ deliantra/server/common/utils.C 2008/04/01 19:50:36 1.72 @@ -471,7 +471,7 @@ void *salloc_ (int n) throw (std::bad_alloc) { -#ifdef PREFER_MALLOC +#if PREFER_MALLOC void *ptr = malloc (n); #else slice_alloc += n; @@ -498,7 +498,7 @@ /******************************************************************************/ -#ifdef DEBUG_SALLOC +#if DEBUG_SALLOC #define MAGIC 0xa1b2c35543deadLL @@ -523,7 +523,7 @@ unsigned long *p = (unsigned long *)ptr; unsigned long s = *--p ^ MAGIC; - if ((*p ^ MAGIC) != size) + if (size != (unsigned long)(*p ^ MAGIC)) LOG (logBacktrace | llevError, "slice free size (%lx) doesn't match alloc size (%lx)\n", size, s); *p = MAGIC;