--- ray/src/hd/rhdisp.c 1999/07/29 15:38:40 3.42 +++ ray/src/hd/rhdisp.c 2003/06/20 00:25:49 3.46 @@ -1,9 +1,6 @@ -/* Copyright (c) 1999 Silicon Graphics, Inc. */ - #ifndef lint -static char SCCSid[] = "$SunId$ SGI"; +static const char RCSid[] = "$Id: rhdisp.c,v 3.46 2003/06/20 00:25:49 greg Exp $"; #endif - /* * Holodeck display process. */ @@ -22,7 +19,9 @@ static char SCCSid[] = "$SunId$ SGI"; #define FSIZDEF 0.125 /* default focus frame size */ #endif -#ifdef linux +#if defined(freebsd) +#define fbufcnt(f) ((f)->_r) +#elif defined(__GNUC__) #define fbufcnt(f) ((f)->_IO_read_end - (f)->_IO_read_ptr) #else #define fbufcnt(f) ((f)->_cnt) @@ -61,7 +60,6 @@ main(argc, argv) int argc; char *argv[]; { - extern int eputs(); int rdy, inp, res = 0, pause = 0; progname = argv[0]; @@ -218,7 +216,7 @@ char *gfn, *pfn; hdlist[hd] = (HOLO *)malloc(sizeof(HOLO)); if (hdlist[hd] == NULL) error(SYSTEM, "out of memory in add_holo"); - bcopy((char *)hdg, (char *)hdlist[hd], sizeof(HDGRID)); + bcopy((void *)hdg, (void *)hdlist[hd], sizeof(HDGRID)); hdcompgrid(hdlist[hd]); hdgfn[hd] = savestr(gfn); hdpfn[hd] = pfn && *pfn ? savestr(pfn) : (char *)NULL; @@ -277,7 +275,7 @@ register VIEW *v; static unsigned nhist; VIEW *dv; int i, res[2]; - int2 *slist; + int16 *slist; char *err; /* restore previous view? */ if (v == NULL) { @@ -481,7 +479,8 @@ serv_result() /* get next server result and process if (buf == NULL) buf = (char *)malloc(bufsiz=msg.nbytes); else - buf = (char *)realloc(buf, bufsiz=msg.nbytes); + buf = (char *)realloc((void *)buf, + bufsiz=msg.nbytes); if (buf == NULL) error(SYSTEM, "out of memory in serv_result"); } @@ -568,6 +567,7 @@ char *p; } +void eputs(s) /* put error message to stderr */ register char *s; { @@ -587,6 +587,7 @@ register char *s; } +void quit(code) /* clean up and exit */ int code; {