From 378d4ce7552df580e3ddd89c2faa9f8c5086d646 Mon Sep 17 00:00:00 2001 From: Uros Majstorovic Date: Wed, 2 Feb 2022 06:25:38 +0100 Subject: renamed crypto -> ext --- ext/libressl/crypto/compat/arc4random_fe310.h | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 ext/libressl/crypto/compat/arc4random_fe310.h (limited to 'ext/libressl/crypto/compat/arc4random_fe310.h') diff --git a/ext/libressl/crypto/compat/arc4random_fe310.h b/ext/libressl/crypto/compat/arc4random_fe310.h new file mode 100644 index 0000000..131b0d3 --- /dev/null +++ b/ext/libressl/crypto/compat/arc4random_fe310.h @@ -0,0 +1,27 @@ +#define _ARC4_LOCK() ; +#define _ARC4_UNLOCK() ; + +static inline void +_getentropy_fail(void) +{ + _exit(1); +} + +static inline void +_rs_forkdetect(void) +{ +} + +int arc4random_alloc(void **rsp, size_t rsp_size, void **rsxp, size_t rsxp_size); + +static inline int +_rs_allocate(struct _rs **rsp, struct _rsx **rsxp) +{ + return arc4random_alloc((void **)rsp, sizeof(**rsp), (void **)rsxp, sizeof(**rsxp)); +} + +void arc4random_close(void) +{ + rs = NULL; + rsx = NULL; +} \ No newline at end of file -- cgit v1.2.3