Symbol: random
bin/sh/var.c
1761
random_val = (random() >> 5) & 0x7FFF;
bin/stty/key.c
221
ip->t.c_iflag = random();
bin/stty/key.c
222
ip->t.c_oflag = random();
bin/stty/key.c
223
ip->t.c_cflag = random();
bin/stty/key.c
224
ip->t.c_lflag = random();
bin/stty/key.c
226
ip->t.c_cc[f] = random() & 0xFF;
bin/stty/key.c
228
ip->t.c_ispeed = random();
bin/stty/key.c
229
ip->t.c_ospeed = random();
common/lib/libc/gen/radixtree.c
1486
n->idx = random();
common/lib/libc/gen/radixtree.c
1489
n->idx |= (uint32_t)random();
common/lib/libc/gen/rpst.c
629
n->n.n_y = random();
common/lib/libc/gen/rpst.c
632
n->n.n_y = random();
common/lib/libc/gen/rpst.c
634
n->n.n_x = random();
common/lib/libc/gen/rpst.c
635
n->n.n_y = random();
common/lib/libc/stdlib/random.c
51
__weak_alias(random,_random)
games/adventure/io.c
184
ch = (*inptr ^ random()) & 0xFF; /* Decrypt input data */
games/adventure/save.c
106
code = (16 * (random() % 6)) + nibble;
games/adventure/save.c
548
*s = (*s ^ random()) & 0xFF; /* Lightly decrypt */
games/adventure/setup.c
102
(unsigned int)('\t' ^ random()) & 0xFF);
games/adventure/setup.c
118
printf("0x%02x,", (unsigned int)(c ^ random()) & 0xFF);
games/arithmetic/arithmetic.c
199
op = keys[random() % nkeys];
games/arithmetic/arithmetic.c
220
left = right * result + random() % right;
games/arithmetic/arithmetic.c
330
value = random() % (maxval + penalty[op][operand]);
games/atc/update.c
355
p.plane_type = random() % 2;
games/atc/update.c
358
rnd = random() % num_starts;
games/atc/update.c
371
while ((rnd2 = random() % num_starts) == rnd)
games/backgammon/common_source/back.h
46
#define rnum(r) ((int)(random()%r))
games/battlestar/extern.h
48
#define rnd(x) (random() % (x))
games/boggle/boggle/bog.c
637
p = (int) (random() % 16);
games/boggle/boggle/bog.c
638
q = (int) (random() % 16);
games/boggle/boggle/bog.c
649
board[i] = cubes[i][random() % 6];
games/canfield/canfield/canfield.c
542
j = random() % decksize;
games/cgram/cgram.c
278
int c = (int)(random() % i);
games/fortune/strfile/strfile.c
451
i = random() % cnt;
games/gomoku/pickmove.c
220
return (random() & 1) != 0;
games/hack/hack.mklev.c
74
#define somex() ((random()%(croom->hx-croom->lx+1))+croom->lx)
games/hack/hack.mklev.c
75
#define somey() ((random()%(croom->hy-croom->ly+1))+croom->ly)
games/hack/rnd.c
73
#define RND(x) ((random()>>3) % x)
games/hunt/hunt/otto.c
576
&& num_turns > 4 + (random() %
games/hunt/hunt/otto.c
589
duck(random() % NUMDIRECTIONS);
games/hunt/hunt/otto.c
601
if (random() % 5 == 0)
games/hunt/huntd/driver.c
888
return (range == 0 ? 0 : random() % range);
games/larn/fortune.c
93
return (flines[random() % NFORTUNES]);
games/mille/roll.c
58
tot += random() % nsides + 1;
games/monop/roll.c
56
tot += (random() % nsides) + 1;
games/phantasia/misc.c
1016
return ((double) (random() & 0x7fff) / 32768.0);
games/phantasia/misc.c
1018
return ((double) random() / 32768.0);
games/phantasia/setup.c
274
return((double) (random() & 0x7fff) / 32768.0);
games/phantasia/setup.c
276
return((double) random() / 32768.0);
games/quiz/quiz.c
238
next = random() % qsize;
games/quiz/quiz.c
248
if (tflag && random() % 100 > 20) {
games/rain/rain.c
108
xpos[j] = random() % cols + 2;
games/rain/rain.c
109
ypos[j] = random() % lines + 2;
games/rain/rain.c
120
x = random() % cols + 2;
games/rain/rain.c
121
y = random() % lines + 2;
games/sail/extern.h
56
#define dieroll() ((random()) % 6 + 1)
games/snake/snake/snake.c
487
p.col = random() % ccnt;
games/snake/snake/snake.c
488
p.line = random() % lcnt;
games/snake/snake/snake.c
645
vp = ((random() >> 6) & 01777) % w;
games/snake/snake/snake.c
893
bonus = ((random() >> 8) & 0377) % 10;
games/trek/ranf.c
50
return (random() % max);
games/trek/ranf.c
57
return random() / (double)RANDOM_MAX;
games/warp/util.h
11
#define myrand() (int)random()
games/worms/worms.c
542
op->opts[(int)random() % op->nopts];
games/worms/worms.c
618
return low + (random() % (high - low + 1));
games/wump/wump.c
205
bat_num += ((random() % (room_num / 2)) + 1);
games/wump/wump.c
206
pit_num += ((random() % (room_num / 2)) + 1);
games/wump/wump.c
307
if (random() % 15 == 1)
games/wump/wump.c
360
if (random() % 6 == 1) {
games/wump/wump.c
373
jump(next_room = (random() % room_num) + 1);
games/wump/wump.c
382
if (random() % 12 < 2) {
games/wump/wump.c
395
next_room = player_loc = (random() % room_num) + 1;
games/wump/wump.c
446
arrow_location = (random() % room_num) + 1;
games/wump/wump.c
450
lnk = (random() % link_num);
games/wump/wump.c
470
chance = random() % 10;
games/wump/wump.c
506
if (random() % (level == EASY ? 12 : 9) < (lastchance += 2)) {
games/wump/wump.c
510
lastchance = random() % 3;
games/wump/wump.c
556
delta = (random() % (room_num - 1)) + 1;
games/wump/wump.c
569
try_again: lnk = (random() % room_num) + 1;
games/wump/wump.c
575
if (random() % 2 == 1)
games/wump/wump.c
629
loc = (random() % room_num) + 1;
games/wump/wump.c
640
loc = (random() % room_num) + 1;
games/wump/wump.c
649
wumpus_loc = (random() % room_num) + 1;
games/wump/wump.c
657
player_loc = (random() % room_num) + 1;
games/wump/wump.c
734
wumpus_loc = cave[wumpus_loc].tunnel[random() % link_num];
include/stdlib.h
179
long random(void);
lib/libc/time/zic.c
82
# if __has_include(<sys/random.h>)
lib/libcurses/PSD.doc/appen.C
83
putting them on one by one in random order,
lib/libm/noieee_src/n_fmod.c
153
x = (double)random();
lib/libm/noieee_src/n_fmod.c
154
y = (double)random();
lib/libradius/radlib.c
638
r = (uint32_t)random();
lib/libradius/radlib.c
796
h->ident = random();
regress/lib/libc/divrem/divremtest.c
163
int32_t low32 = random();
regress/lib/libc/divrem/divremtest.c
164
int64_t low64 = (intmax_t)random() << 32 | low32;
regress/lib/libc/divrem/divremtest.c
166
a32 = random();
regress/lib/libc/divrem/divremtest.c
167
b32 = random();
regress/lib/libc/divrem/divremtest.c
168
a64 = ((intmax_t)random() << 32) | a32;
regress/lib/libc/divrem/divremtest.c
169
b64 = ((intmax_t)random() << 32) | b32;
regress/lib/libc/ieeefp/testfloat/include/random.h
40
#define randomUint8() ((uint8_t)random())
regress/lib/libc/ieeefp/testfloat/include/random.h
41
#define randomUint16() ((uint16_t)random())
regress/lib/libc/ieeefp/testfloat/include/random.h
42
#define randomUint32() ((uint32_t)random())
regress/lib/libc/ieeefp/testfloat/include/random.h
43
#define randomUint64() ((uint64_t)random() << 32 | random())
regress/sys/fs/lfs/9994/9994_f.c
105
hoge[i] = random() & 0xff;
regress/sys/fs/lfs/9994/9994_f.c
138
j = random() % 3;
regress/sys/fs/lfs/9994/9994_f.c
139
k = random() & 0x3fffff;
regress/sys/fs/lfs/9994/9994_f.c
183
j = random() % (100 * 1000);
regress/sys/kern/select/select.c
103
if (random() & 1) {
regress/sys/kern/select/select.c
115
to.tv_sec = random() % 10;
regress/sys/kern/select/select.c
116
to.tv_usec = random() % 1000000;
regress/sys/kern/select/select.c
66
i = random() % NPIPE;
sbin/efi/main.c
470
opt.mbr_sig = (uint32_t)random();
sbin/mount_qemufwcfg/virtdir.c
143
tp->v[tp->c].ino = (ino_t) random() & 0xfffff;
sbin/newfs_udf/udf_core.c
4513
primary_nr = (uint32_t) random();
sbin/newfs_udf/udf_core.c
4523
volset_nr = (uint64_t) random();
share/examples/refuse/virtdir/virtdir.c
157
tp->v[tp->c].ino = (ino_t) random() & 0xfffff;
sys/arch/arm/footbridge/footbridge_clock.c
163
r = random() & (statvar-1);
sys/arch/arm/imx/if_enet.c
189
uint32_t eaddr = random();
sys/arch/arm/imx/if_enet.c
195
eaddr = random();
sys/arch/atari/dev/clock.c
258
r = random() & var;
sys/arch/evbarm/ifpga/ifpga_clock.c
157
r = random() & (var - 1);
sys/arch/hp300/hp300/clock.c
292
r = random() & (var - 1);
sys/arch/hpcmips/tx/tx39.c
196
magic0 = random();
sys/arch/hpcmips/tx/tx39.c
197
magic1 = random();
sys/arch/hpcmips/vr/vr.c
371
x = random();
sys/arch/hpcmips/vr/vr.c
379
x = random();
sys/arch/hpcsh/dev/hd64461/hd64461video.c
1096
x = random();
sys/arch/hpcsh/hpcsh/machdep.c
520
x = random();
sys/arch/hpcsh/hpcsh/machdep.c
566
x = random();
sys/arch/hpcsh/hpcsh/machdep.c
572
x = random();
sys/arch/sparc/sparc/timervar.h
85
r = random() & (var - 1);
sys/arch/sparc64/sparc64/clock.c
733
r = random() & (var - 1);
sys/arch/virt68k/include/clockvar.h
71
do { r = random() & (var - 1); } while (r == 0); \
sys/dev/mvme/clockvar.h
64
do { r = random() & (var - 1); } while (r == 0); \
sys/dev/pci/if_bnxreg.h
163
#define DB_RANDOMFALSE(defects) (random() > (defects))
sys/dev/pci/if_bnxreg.h
164
#define DB_OR_RANDOMFALSE(defects) || (random() > (defects))
sys/dev/pci/if_bnxreg.h
165
#define DB_AND_RANDOMFALSE(defects) && (random() > (defects))
sys/dev/pci/if_bnxreg.h
168
#define DB_RANDOMTRUE(defects) (random() < (defects))
sys/dev/pci/if_bnxreg.h
169
#define DB_OR_RANDOMTRUE(defects) || (random() < (defects))
sys/dev/pci/if_bnxreg.h
170
#define DB_AND_RANDOMTRUE(defects) && (random() < (defects))
sys/fs/ntfs/ntfs_vnops.c
155
<other random data follows, presumably>
sys/lib/libkern/libkern.h
455
long random(void);
sys/miscfs/genfs/genfs_vnops.c
219
/ * other random data follows, presumably * /
sys/miscfs/genfs/layer_vnops.c
226
<other random data follows, presumably>
sys/miscfs/umapfs/umap_vnops.c
118
<other random data follows, presumably>
sys/netinet/dccp_usrreq.c
1717
dp->seq_snd = (((u_int64_t)random() << 32) | random()) % 281474976710656LL;
sys/netinet/dccp_usrreq.c
471
dp->seq_snd = (((u_int64_t)random() << 32) | random()) % 281474976710656LL;
sys/netinet6/dccp6_usrreq.c
188
dp->seq_snd = (((u_int64_t)random() << 32) | random()) % 281474976710656LL;
tests/crypto/opencrypto/h_comp_zlib_rnd.c
53
*(long *)(text + i * sizeof(long)) = random();
tests/fs/lfs/util.c
121
b = (((unsigned)random()) & 0xff);
tests/fs/lfs/util.c
78
random();
tests/fs/lfs/util.c
85
buf[j] = ((unsigned)random()) & 0xff;
tests/fs/puffs/h_dtfs/dtfs_subr.c
64
vap->va_gen = random();
tests/h_macros.h
80
*sb++ = (uint16_t)random();
tests/h_macros.h
83
randval = (uint16_t)random();
tests/include/sys/t_tree.c
88
m[i] = addmist(random() << 1); /* use all 32 bits */
tests/lib/libc/stdlib/t_random.c
64
buf[i] = random();
tests/lib/libc/string/t_memcpy.c
67
b1[n] = (unsigned char)random();
tests/lib/libc/string/t_memcpy.c
68
b2[n] = (unsigned char)random();
tests/lib/libpthread/h_resolv.c
98
size_t i = (random() & 0x0fffffff) % hosts->sl_cur;
tests/rump/rumpkern/h_client/h_reconcli.c
33
usleep(random() % 100000);
tests/sys/uvm/t_uvm_physseg_load.c
344
pa = (paddr_t) random() % (paddr_t) ctob(VALID_END_PFN_1);
tests/sys/uvm/t_uvm_physseg_load.c
373
pa = (paddr_t) random() % (paddr_t) ctob(VALID_END_PFN_1);
tests/sys/uvm/t_uvm_physseg_load.c
402
pa = (paddr_t) random() % (paddr_t) ctob(VALID_END_PFN_1);
tests/sys/uvm/t_uvm_physseg_load.c
431
pa = (paddr_t) random() % (paddr_t) ctob(VALID_END_PFN_1);
tests/sys/uvm/t_uvm_physseg_load.c
460
pa = (paddr_t) random() % (paddr_t) ctob(VALID_END_PFN_1);
tests/sys/uvm/t_uvm_physseg_load.c
489
pa = (paddr_t) random() % (paddr_t) ctob(VALID_END_PFN_1);
tests/sys/uvm/t_uvm_physseg_load.c
518
pa = (paddr_t) random() % (paddr_t) ctob(VALID_END_PFN_1);
tests/sys/uvm/t_uvm_physseg_load.c
560
pf_chunk_size = (psize_t) random() % (psize_t) (PF_STEP - 1) + 1;
tests/sys/uvm/t_uvm_physseg_load.c
565
pa = (paddr_t) random() % (paddr_t) ctob(VALID_END_PFN_2);
tests/sys/uvm/t_uvm_physseg_load.c
609
pf_chunk_size = (psize_t) random() % (psize_t) (PF_STEP - 1) + 1;
tests/sys/uvm/t_uvm_physseg_load.c
614
pa = (paddr_t) random() % (paddr_t) ctob(VALID_END_PFN_3);
tests/sys/uvm/t_uvm_physseg_load.c
658
pf_chunk_size = (psize_t) random() % (psize_t) (PF_STEP - 1) + 1;
tests/sys/uvm/t_uvm_physseg_load.c
663
pa = (paddr_t) random() % (paddr_t) ctob(VALID_END_PFN_4);
tests/sys/uvm/t_uvm_physseg_load.c
706
pf_chunk_size = (psize_t) random() % (psize_t) (PF_STEP - 1) + 1;
tests/sys/uvm/t_uvm_physseg_load.c
711
pa = (paddr_t) random() % (paddr_t) ctob(VALID_END_PFN_5);
tests/usr.bin/xlint/lint1/msg_092.c
17
random();
tests/usr.bin/xlint/lint1/msg_092.c
22
static double random(void);
usr.bin/btpin/btpin.c
129
*pin++ = '0' + (random() % 10);
usr.bin/jot/jot.c
120
putdata(random() * x + begin, reps - i);
usr.bin/make/compat.c
460
size_t i = (size_t)random() % r;
usr.bin/make/make.c
934
i = n > 0 ? (size_t)random() % (n + 1) : 0;
usr.bin/make/var.c
3447
size_t rndidx = (size_t)random() % (i + 1);
usr.sbin/makefs/ffs.c
1158
dip->di_gen = random() / 2 + 1;
usr.sbin/makefs/ffs/mkfs.c
468
sblock.fs_id[1] = random();
usr.sbin/makefs/ffs/mkfs.c
801
dp1->di_gen = random();
usr.sbin/makefs/ffs/mkfs.c
804
dp2->di_gen = random();
usr.sbin/makefs/ffs/mkfs.c
819
dp1->di_gen = random();
usr.sbin/npf/npftest/libnpftest/npf_nbuf_test.c
147
off = (random() % 16) + 1;
usr.sbin/npf/npftest/libnpftest/npf_nbuf_test.c
148
len = (random() % 16) + 1;
usr.sbin/npf/npftest/libnpftest/npf_nbuf_test.c
41
nptr = nbuf_advance(&nbuf, (random() % 16) + 1, (random() % 16) + 1);
usr.sbin/npf/npftest/libnpftest/npf_test_subr.c
277
return (uint32_t)(_random_func ? _random_func() : random());
usr.sbin/npf/npftest/npftest.c
276
rumpns_npf_test_init(inet_pton, inet_ntop, random);