]> ncurses.scripts.mit.edu Git - ncurses.git/blobdiff - test/movewindow.c
ncurses 5.6 - patch 20080412
[ncurses.git] / test / movewindow.c
index a45121db91d6e732969a902868cee1874414f672..d826e58dcbd4d66d21bcf443ce7a8efcc894321a 100644 (file)
@@ -26,7 +26,7 @@
  * authorization.                                                           *
  ****************************************************************************/
 /*
  * authorization.                                                           *
  ****************************************************************************/
 /*
- * $Id: movewindow.c,v 1.21 2008/02/09 18:08:28 tom Exp $
+ * $Id: movewindow.c,v 1.22 2008/04/12 22:01:41 tom Exp $
  *
  * Demonstrate move functions for windows and derived windows from the curses
  * library.
  *
  * Demonstrate move functions for windows and derived windows from the curses
  * library.
@@ -251,7 +251,7 @@ add_window(WINDOW *parent, WINDOW *child)
 
     keypad(child, TRUE);
     if (need > have) {
 
     keypad(child, TRUE);
     if (need > have) {
-       all_windows = (FRAME *) realloc(all_windows, need * sizeof(FRAME));
+       all_windows = typeRealloc(FRAME, need, all_windows);
     }
     all_windows[num_windows].parent = parent;
     all_windows[num_windows].child = child;
     }
     all_windows[num_windows].parent = parent;
     all_windows[num_windows].child = child;