#include <ctype.h>
#include <tic.h>
-MODULE_ID("$Id: comp_scan.c,v 1.92 2011/07/30 21:36:33 tom Exp $")
+MODULE_ID("$Id: comp_scan.c,v 1.94 2011/10/22 15:46:43 tom Exp $")
/*
* Maximum length of string capability we'll accept before raising an error.
}
static void
-push_back(char c)
+push_back(int c)
/* push a character back onto the input stream */
{
if (bufptr == bufstart)
_nc_syserr_abort("Can't backspace off beginning of line");
- *--bufptr = c;
+ *--bufptr = (char) c;
_nc_curr_col--;
}
if (!(is7bits(c) && isprint(c))) {
_nc_warning("Illegal ^ character - '%s'", unctrl(UChar(c)));
}
- if (c == '?') {
+ if (c == '?' && (_nc_syntax != SYN_TERMCAP)) {
*(ptr++) = '\177';
if (_nc_tracing)
_nc_warning("Allow ^? as synonym for \\177");
/* allow the digit; it'll do less harm */
}
} else {
- push_back((char) c);
+ push_back(c);
break;
}
}
if (!ignored) {
if (_nc_curr_col <= 1) {
- push_back((char) c);
+ push_back(c);
c = '\n';
break;
}