Changes in uspace/lib/c/generic/stdlib.c [c718bda:ff98ce8] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/c/generic/stdlib.c
rc718bda rff98ce8 35 35 #include <stdlib.h> 36 36 37 static intglbl_seed = 1;37 static long glbl_seed = 1; 38 38 39 int rand(void)39 long int random(void) 40 40 { 41 41 return glbl_seed = ((1366 * glbl_seed + 150889) % RAND_MAX); 42 42 } 43 43 44 void srand (unsigned int seed)44 void srandom(unsigned int seed) 45 45 { 46 46 glbl_seed = seed % RAND_MAX;
Note:
See TracChangeset
for help on using the changeset viewer.