Initialize random
This commit is contained in:
ache 1997-09-24 21:16:13 +00:00
parent 1b464282d7
commit 4525d7b15b

View File

@ -54,6 +54,9 @@ static char sccsid[] = "@(#)rain.c 8.1 (Berkeley) 5/31/93";
#include <sgtty.h>
#endif
#include <signal.h>
#include <termcap.h>
#include <stdlib.h>
#include <string.h>
#define cursor(c, r) tputs(tgoto(CM, c, r), 1, fputchar)
@ -64,7 +67,7 @@ static struct sgttyb sg, old_tty;
#endif
int fputchar();
char *LL, *TE, *tgoto();
char *LL, *TE;
main(argc, argv)
int argc;
@ -74,9 +77,8 @@ main(argc, argv)
extern char *UP;
register int x, y, j;
register char *CM, *BC, *DN, *ND, *term;
char *TI, *tcp, *mp, tcb[100],
*malloc(), *getenv(), *strcpy(), *tgetstr();
long cols, lines, random();
char *TI, *tcp, *mp, tcb[100];
long cols, lines;
int xpos[5], ypos[5];
static void onsig();
@ -119,6 +121,7 @@ main(argc, argv)
}
(void)strcpy(LL, tgoto(CM, 0, 23));
}
srandomdev();
#ifdef USG
ioctl(1, TCGETA, &sg);
ospeed = sg.c_cflag&CBAUD;