mirror of
https://github.com/opnsense/src.git
synced 2026-06-09 00:32:25 -04:00
Cleanup
Convert to random()
This commit is contained in:
parent
7df134f1fd
commit
6e429392ac
3 changed files with 4 additions and 3 deletions
|
|
@ -91,6 +91,6 @@ run:
|
|||
case 0:
|
||||
goto start;
|
||||
default:
|
||||
exit();
|
||||
exit(0);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -37,11 +37,12 @@
|
|||
#include <sys/param.h>
|
||||
#include <sys/signal.h>
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
|
||||
#define BITS (8)
|
||||
|
||||
#define OUTSIDE (position > 68 && position < 246 && position != 218)
|
||||
#define rnd(x) (rand() % (x))
|
||||
#define rnd(x) (random() % (x))
|
||||
#define max(a,b) ((a) < (b) ? (b) : (a))
|
||||
#define testbit(array, index) (array[index/BITS] & (1 << (index % BITS)))
|
||||
#ifndef setbit
|
||||
|
|
|
|||
|
|
@ -48,7 +48,7 @@ initialize(startup)
|
|||
puts("Version 4.2, fall 1984.");
|
||||
puts("First Adventure game written by His Lordship, the honorable");
|
||||
puts("Admiral D.W. Riggle\n");
|
||||
srand(getpid());
|
||||
srandomdev();
|
||||
getutmp(uname);
|
||||
if (startup)
|
||||
location = dayfile;
|
||||
|
|
|
|||
Loading…
Reference in a new issue