summary refs log tree commit diff
path: root/Src
diff options
context:
space:
mode:
authorBart Schaefer <barts@users.sourceforge.net>2001-04-21 21:41:28 +0000
committerBart Schaefer <barts@users.sourceforge.net>2001-04-21 21:41:28 +0000
commit6bf2ff17175946b9c038f041f8828bceb59565aa (patch)
tree2d8af6e939ae601234fa91ee0870edca54ea0f59 /Src
parent219674c48b0956fe8ed9e6e6c795eeca90f41b5a (diff)
downloadzsh-6bf2ff17175946b9c038f041f8828bceb59565aa.tar.gz
zsh-6bf2ff17175946b9c038f041f8828bceb59565aa.tar.xz
zsh-6bf2ff17175946b9c038f041f8828bceb59565aa.zip
More term*.h inclusion un-confusion.
Diffstat (limited to 'Src')
-rw-r--r--Src/Modules/termcap.c28
1 files changed, 16 insertions, 12 deletions
diff --git a/Src/Modules/termcap.c b/Src/Modules/termcap.c
index 35fb71f64..fbaf887c1 100644
--- a/Src/Modules/termcap.c
+++ b/Src/Modules/termcap.c
@@ -37,20 +37,22 @@ static char termcap_nam[] = "termcap";
 /* echotc: output a termcap */
 
 #ifdef HAVE_TGETENT
-# ifdef HAVE_TERMCAP_H
-#  include <termcap.h>
-#  ifdef HAVE_TERM_H
-#   include <term.h>
-#  endif
-# else
+# if defined(HAVE_CURSES_H) && defined(HAVE_TERM_H)
 #  ifdef HAVE_TERMIO_H
 #   include <termio.h>
 #  endif
-#  ifdef HAVE_CURSES_H
-#   include <curses.h>
-#  endif
-#  ifdef HAVE_TERM_H
-#   include <term.h>
+#  include <curses.h>
+#  include <term.h>
+# else
+#  ifdef HAVE_TERMCAP_H
+#   include <termcap.h>
+#  else
+#   ifdef HAVE_CURSES_H
+#    include <curses.h>
+#   endif
+#   ifdef HAVE_TERM_H
+#    include <term.h>
+#   endif
 #  endif
 # endif
 
@@ -356,7 +358,9 @@ int
 boot_(Module m)
 {
 #ifdef HAVE_TGETENT
+# if defined(HAVE_CURSES_H) && defined(HAVE_TERM_H)
     setupterm((char *)0, 1, (int *)0);
+# endif
 
     if (!createtchash())
     	return 1;
@@ -376,7 +380,7 @@ cleanup_(Module m)
 
     incleanup = 1;
 
-#ifdef HAVE_TGETENTR
+#ifdef HAVE_TGETENT
     if ((pm = (Param) paramtab->getnode(paramtab, termcap_nam)) &&
 	pm == termcap_pm) {
 	pm->flags &= ~PM_READONLY;