$OpenBSD: patch-lex_c,v 1.6 2011/06/26 09:48:50 sthen Exp $ --- lex.c.orig Sat Jun 25 23:40:11 2011 +++ lex.c Sat Jun 25 23:39:40 2011 @@ -34,6 +34,8 @@ #include #include #include +#include +#include #include "sc.h" #ifdef NONOTIMEOUT @@ -107,7 +109,7 @@ int yylex() { char *p = line + linelim; - int ret; + int ret = 0; static int isfunc = 0; static bool isgoto = 0; static bool colstate = 0; @@ -642,7 +644,7 @@ nmgetch() #endif -#if defined(SYSV2) || defined(SYSV3) || defined(MSDOS) +#if defined(SYSV2) || defined(SYSV3) || defined(MSDOS) || defined(NCURSES_VERSION) void initkbd()