]> ncurses.scripts.mit.edu Git - ncurses.git/blobdiff - ncurses/tinfo/lib_termcap.c
ncurses 5.7 - patch 20091219
[ncurses.git] / ncurses / tinfo / lib_termcap.c
index 064383dbd5cca12b47fea85f9d83611b35c5de04..893d117d3d28f1778bec1d27ca29ad3d58442f55 100644 (file)
@@ -50,7 +50,7 @@
 #define CUR SP_TERMTYPE
 #endif
 
 #define CUR SP_TERMTYPE
 #endif
 
-MODULE_ID("$Id: lib_termcap.c,v 1.69 2009/07/11 18:14:21 tom Exp $")
+MODULE_ID("$Id: lib_termcap.c,v 1.71 2009/10/24 21:56:58 tom Exp $")
 
 NCURSES_EXPORT_VAR(char *) UP = 0;
 NCURSES_EXPORT_VAR(char *) BC = 0;
 
 NCURSES_EXPORT_VAR(char *) UP = 0;
 NCURSES_EXPORT_VAR(char *) BC = 0;
@@ -93,15 +93,13 @@ NCURSES_SP_NAME(tgetent) (NCURSES_SP_DCLx char *bufp, const char *name)
     START_TRACE();
     T((T_CALLED("tgetent()")));
 
     START_TRACE();
     T((T_CALLED("tgetent()")));
 
-#ifdef USE_TERM_DRIVER
-    _nc_setupterm_ex(&termp, (NCURSES_CONST char *) name,
+    TINFO_SETUP_TERM(&termp, (NCURSES_CONST char *) name,
                     STDOUT_FILENO, &errcode, TRUE);
 
                     STDOUT_FILENO, &errcode, TRUE);
 
+#ifdef USE_TERM_DRIVER
     if (termp == 0 ||
        !((TERMINAL_CONTROL_BLOCK *) termp)->drv->isTerminfo)
        return (errcode);
     if (termp == 0 ||
        !((TERMINAL_CONTROL_BLOCK *) termp)->drv->isTerminfo)
        return (errcode);
-#else
-    _nc_setupterm((NCURSES_CONST char *) name, STDOUT_FILENO, &errcode, TRUE);
 #endif
 
     /*
 #endif
 
     /*
@@ -228,7 +226,7 @@ NCURSES_SP_NAME(tgetflag) (NCURSES_SP_DCLx NCURSES_CONST char *id)
     int result = 0;            /* Solaris returns zero for missing flag */
     int i, j;
 
     int result = 0;            /* Solaris returns zero for missing flag */
     int i, j;
 
-    T((T_CALLED("tgetflag(%p, %s)"), SP_PARM, id));
+    T((T_CALLED("tgetflag(%p, %s)"), (void *) SP_PARM, id));
     if (HasTInfoTerminal(SP_PARM)) {
        TERMTYPE *tp = &(TerminalOf(SP_PARM)->type);
        struct name_table_entry const *entry_ptr;
     if (HasTInfoTerminal(SP_PARM)) {
        TERMTYPE *tp = &(TerminalOf(SP_PARM)->type);
        struct name_table_entry const *entry_ptr;
@@ -280,7 +278,7 @@ NCURSES_SP_NAME(tgetnum) (NCURSES_SP_DCLx NCURSES_CONST char *id)
     int result = ABSENT_NUMERIC;
     int i, j;
 
     int result = ABSENT_NUMERIC;
     int i, j;
 
-    T((T_CALLED("tgetnum(%p, %s)"), SP_PARM, id));
+    T((T_CALLED("tgetnum(%p, %s)"), (void *) SP_PARM, id));
     if (HasTInfoTerminal(SP_PARM)) {
        TERMTYPE *tp = &(TerminalOf(SP_PARM)->type);
        struct name_table_entry const *entry_ptr;
     if (HasTInfoTerminal(SP_PARM)) {
        TERMTYPE *tp = &(TerminalOf(SP_PARM)->type);
        struct name_table_entry const *entry_ptr;
@@ -332,7 +330,7 @@ NCURSES_SP_NAME(tgetstr) (NCURSES_SP_DCLx NCURSES_CONST char *id, char **area)
     char *result = NULL;
     int i, j;
 
     char *result = NULL;
     int i, j;
 
-    T((T_CALLED("tgetstr(%s,%p)"), id, area));
+    T((T_CALLED("tgetstr(%s,%p)"), id, (void *) area));
     if (HasTInfoTerminal(SP_PARM)) {
        TERMTYPE *tp = &(TerminalOf(SP_PARM)->type);
        struct name_table_entry const *entry_ptr;
     if (HasTInfoTerminal(SP_PARM)) {
        TERMTYPE *tp = &(TerminalOf(SP_PARM)->type);
        struct name_table_entry const *entry_ptr;