Skip to content

Commit a68d3ed

Browse files
carbotaniumanJohnTitor
authored andcommitted
Add rand48 functions
1 parent 2dfe1ab commit a68d3ed

File tree

2 files changed

+19
-0
lines changed

2 files changed

+19
-0
lines changed

libc-test/semver/linux.txt

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2872,6 +2872,7 @@ dirfd
28722872
dl_iterate_phdr
28732873
dl_phdr_info
28742874
dqblk
2875+
drand48
28752876
dup3
28762877
duplocale
28772878
endgrent
@@ -2885,6 +2886,7 @@ epoll_ctl
28852886
epoll_event
28862887
epoll_pwait
28872888
epoll_wait
2889+
erand48
28882890
eventfd
28892891
execvpe
28902892
faccessat
@@ -2991,15 +2993,18 @@ ip_mreq_source
29912993
ipc_perm
29922994
itimerspec
29932995
j1939_filter
2996+
jrand48
29942997
key_t
29952998
killpg
29962999
labs
3000+
lcong48
29973001
lgetxattr
29983002
listxattr
29993003
llistxattr
30003004
lockf
30013005
loff_t
30023006
login_tty
3007+
lrand48
30033008
lremovexattr
30043009
lseek64
30053010
lsetxattr
@@ -3034,6 +3039,7 @@ mq_timedreceive
30343039
mq_timedsend
30353040
mq_unlink
30363041
mqd_t
3042+
mrand48
30373043
mremap
30383044
msgctl
30393045
msgget
@@ -3053,6 +3059,7 @@ nl_langinfo_l
30533059
nlattr
30543060
nlmsgerr
30553061
nlmsghdr
3062+
nrand48
30563063
off64_t
30573064
open64
30583065
open_how
@@ -3171,6 +3178,7 @@ sched_setaffinity
31713178
sched_setparam
31723179
sched_setscheduler
31733180
seccomp_data
3181+
seed48
31743182
seekdir
31753183
sem_close
31763184
sem_destroy
@@ -3231,6 +3239,7 @@ sockaddr_vm
32313239
splice
32323240
spwd
32333241
srand
3242+
srand48
32343243
stack_t
32353244
stat64
32363245
statfs

src/unix/linux_like/linux/mod.rs

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3710,6 +3710,16 @@ extern "C" {
37103710
pub fn rand() -> ::c_int;
37113711
pub fn srand(seed: ::c_uint);
37123712

3713+
pub fn drand48() -> ::c_double;
3714+
pub fn erand48(xseed: *mut ::c_ushort) -> ::c_double;
3715+
pub fn lrand48() -> ::c_long;
3716+
pub fn nrand48(xseed: *mut ::c_ushort) -> ::c_long;
3717+
pub fn mrand48() -> ::c_long;
3718+
pub fn jrand48(xseed: *mut ::c_ushort) -> ::c_long;
3719+
pub fn srand48(seed: ::c_long);
3720+
pub fn seed48(xseed: *mut ::c_ushort) -> *mut ::c_ushort;
3721+
pub fn lcong48(p: *mut ::c_ushort);
3722+
37133723
pub fn lutimes(file: *const ::c_char, times: *const ::timeval) -> ::c_int;
37143724

37153725
pub fn setpwent();

0 commit comments

Comments
 (0)