/* This file is part of the YAZ toolkit.
- * Copyright (C) 1995-2009 Index Data
+ * Copyright (C) 1995-2012 Index Data
* See the file LICENSE for details.
*/
/**
}
if (log_level)
- yaz_log (log_level,
- "%s:%d: xrealloc(s=%ld) %p -> %p", file, line, (long) size, o, p);
+ yaz_log(log_level,
+ "%s:%d: xrealloc(s=%ld) %p -> %p", file, line, (long) size, o, p);
if (!p)
{
- yaz_log (YLOG_FATAL|YLOG_ERRNO, "Out of memory, realloc (%ld bytes)",
- (long) size);
+ yaz_log(YLOG_FATAL|YLOG_ERRNO, "Out of memory, realloc (%ld bytes)",
+ (long) size);
xmalloc_fatal();
}
return p;
if (l < n)
return xstrdup_f(s, file, line);
{
- char *a = xmalloc_f(n+1, file, line);
+ char *a = (char*) xmalloc_f(n+1, file, line);
memcpy(a, s, n);
a[n] = '\0';
return a;