]> ncurses.scripts.mit.edu Git - ncurses.git/blobdiff - test/demo_menus.c
ncurses 5.9 - patch 20121102
[ncurses.git] / test / demo_menus.c
index 7a3db9cf3863091bd28400e6743cea18807dd0d8..8f19281dfa6945d06119cfbfabac1d8b983b5aa8 100644 (file)
@@ -26,7 +26,7 @@
  * authorization.                                                           *
  ****************************************************************************/
 /*
- * $Id: demo_menus.c,v 1.34 2012/06/09 20:30:33 tom Exp $
+ * $Id: demo_menus.c,v 1.36 2012/11/03 19:27:01 tom Exp $
  *
  * Demonstrate a variety of functions from the menu library.
  * Thomas Dickey - 2005/4/9
@@ -109,18 +109,6 @@ static MENU *mpSelect;
 
 static bool loaded_file = FALSE;
 
-#if !HAVE_STRDUP
-#define strdup my_strdup
-static char *
-strdup(char *s)
-{
-    char *p = typeMalloc(char, strlen(s) + 1);
-    if (p)
-       strcpy(p, s);
-    return (p);
-}
-#endif /* not HAVE_STRDUP */
-
 /* Common function to allow ^T to toggle trace-mode in the middle of a test
  * so that trace-files can be made smaller.
  */
@@ -867,7 +855,7 @@ main(int argc, char *argv[])
 #endif /* HAVE_RIPOFFLINE */
 #ifdef TRACE
        case 't':
-           trace(strtoul(optarg, 0, 0));
+           trace((unsigned) strtoul(optarg, 0, 0));
            break;
 #endif
        default: