Commit fa5a266f authored by Niels Möller's avatar Niels Möller
Browse files

* src/xalloc.h (lsh_realloc): New define.

* src/xalloc.c (lsh_space_realloc): New function.

Rev: src/xalloc.c:1.36
Rev: src/xalloc.h:1.33
parent 854c8fff
......@@ -298,7 +298,6 @@ void lsh_space_free(const void *p)
void *lsh_space_realloc(void *p, size_t size)
{
if (!size)
{
lsh_space_free(p);
......@@ -330,4 +329,8 @@ void lsh_space_free(const void *p)
lsh_free(p);
}
void *lsh_space_realloc(void *p, size_t size)
{
return xrealloc(p, size);
}
#endif /* !DEBUG_ALLOC */
......@@ -49,6 +49,7 @@ debug_free(const void *m);
* of the few things that C++ gets right). */
#define lsh_free(p) free((void *) (p))
#define lsh_malloc malloc
#define lsh_realloc realloc
#endif /* !DEBUG_ALLOC */
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment