musl-tcc/src/prng/seed48.c

12 lines
211 B
C
Raw Normal View History

2022-03-20 08:48:53 +00:00
#include <stdlib.h>
#include <string.h>
#include "rand48.h"
unsigned short *seed48(unsigned short *s)
{
static unsigned short p[3];
memcpy(p, __seed48, sizeof p);
memcpy(__seed48, s, sizeof p);
return p;
}