summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--term-utils/setterm.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/term-utils/setterm.c b/term-utils/setterm.c
index 310c3fab0..d41e335a8 100644
--- a/term-utils/setterm.c
+++ b/term-utils/setterm.c
@@ -100,16 +100,17 @@
#include <termios.h>
#include <string.h>
#include <fcntl.h>
+
#ifndef NCURSES_CONST
#define NCURSES_CONST const /* define before including term.h */
#endif
-#include <term.h>
-
#ifdef HAVE_NCURSES_H
#include <ncurses.h>
#elif defined(HAVE_NCURSES_NCURSES_H)
#include <ncurses/ncurses.h>
#endif
+/* must include after ncurses.h */
+#include <term.h>
#include <sys/param.h> /* for MAXPATHLEN */
#include <sys/ioctl.h>