Fix some compilation warnings

This commit is contained in:
Paul Traina 1996-09-22 01:05:21 +00:00
parent 79b3126fb3
commit 04bd4759a8
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=18454
6 changed files with 13 additions and 22 deletions

View File

@ -56,7 +56,7 @@ chtype ch = c;
T(("win attr = %x", win->_attrs));
ch |= win->_attrs;
if (win->_line[y][x]&A_CHARTEXT == ' ')
if ((win->_line[y][x]&A_CHARTEXT) == ' ')
ch |= win->_bkgd;
else
ch |= (win->_bkgd&A_ATTRIBUTES);

View File

@ -27,7 +27,7 @@ int x, y;
T(("wbkgd(%x, %x) called", win, ch));
for (y = 0; y < win->_maxy; y++)
for (x = 0; x < win->_maxx; x++)
if (win->_line[y][x]&A_CHARTEXT == ' ')
if ((win->_line[y][x]&A_CHARTEXT) == ' ')
win->_line[y][x] |= ch;
else
win->_line[y][x] |= (ch&A_ATTRIBUTES);

View File

@ -12,7 +12,7 @@
#include "curses.priv.h"
#define BLANK ' '|A_NORMAL
#define BLANK (' '|A_NORMAL)
int wclrtobot(WINDOW *win)
{

View File

@ -12,7 +12,7 @@
#include "curses.priv.h"
#define BLANK ' '|A_NORMAL
#define BLANK (' '|A_NORMAL)
int wclrtoeol(WINDOW *win)
{

View File

@ -195,7 +195,7 @@ static int countc(int c)
**
*/
#define BLANK ' '|A_NORMAL
#define BLANK (' '|A_NORMAL)
static void ClrUpdate(WINDOW *scr)
{

View File

@ -37,18 +37,10 @@ static char sccsid[] = "@(#)termout.c 8.1 (Berkeley) 6/6/93";
#if defined(unix)
#include <signal.h>
#include <sgtty.h>
#include <termios.h>
#endif
#include <stdio.h>
#include <curses.h>
#if defined(ultrix)
/* Some version of this OS has a bad definition for nonl() */
#undef nl
#undef nonl
#define nl() (_tty.sg_flags |= CRMOD,_pfast = _rawmode,stty(_tty_ch, &_tty))
#define nonl() (_tty.sg_flags &= ~CRMOD, _pfast = TRUE, stty(_tty_ch, &_tty))
#endif /* defined(ultrix) */
#include "../general/general.h"
@ -628,9 +620,8 @@ void
InitTerminal()
{
#if defined(unix)
struct sgttyb ourttyb;
static int speeds[] = { 0, 50, 75, 110, 134, 150, 200, 300, 600, 1200, 1800,
2400, 4800, 9600 };
struct termios termios_info;
speed_t speed;
#endif
extern void InitMapping();
@ -657,14 +648,14 @@ InitTerminal()
TryToSend = FastScreen;
#if defined(unix)
ioctl(1, TIOCGETP, (char *) &ourttyb);
if ((ourttyb.sg_ospeed < 0) || (ourttyb.sg_ospeed > B9600)) {
(void) tcgetattr(1, &termios_info);
speed = cfgetospeed(&termios_info);
if (speed > 19200) {
max_changes_before_poll = 1920;
} else {
max_changes_before_poll = speeds[ourttyb.sg_ospeed]/10;
if (max_changes_before_poll < 40) {
max_changes_before_poll = speed/10;
if (max_changes_before_poll < 40)
max_changes_before_poll = 40;
}
TryToSend = SlowScreen;
HaveInput = 1; /* get signals going */
}