****************************************************************************/
#include <curses.priv.h>
-#include <term.h>
-MODULE_ID("$Id: wresize.c,v 1.9 1998/02/11 12:13:54 tom Exp $")
+MODULE_ID("$Id: wresize.c,v 1.12 1999/02/27 18:57:31 tom Exp $")
/*
* Reallocate a curses WINDOW struct to either shrink or grow to the specified
* blanks. The application is responsible for repainting the blank area.
*/
-static void *doalloc(void *p, size_t n)
-{
- if (p == 0)
- p = malloc(n);
- else
- p = realloc(p, n);
- return p;
-}
-
-#define DOALLOC(p,t,n) (t *)doalloc(p, sizeof(t)*(n))
+#define DOALLOC(p,t,n) typeRealloc(t, n, p)
#define ld_ALLOC(p,n) DOALLOC(p,struct ldat,n)
#define c_ALLOC(p,n) DOALLOC(p,chtype,n)