aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorLibravatarLibravatar William Ahern <william@25thandClement.com> 2016-01-08 01:07:28 +0800
committerLibravatarLibravatar William Ahern <william@25thandClement.com> 2016-01-08 01:07:28 +0800
commitfbc2058139566d2530d72ec5e77daf9847ffe252 (patch)
tree111f0d7796cd6f3504fd326be556a5d96a671c0f /src
parent9362e313739931ca8f62aa94eb6b11325e95bdb2 (diff)
downloadluaossl-fbc2058139566d2530d72ec5e77daf9847ffe252.tar.gz
luaossl-fbc2058139566d2530d72ec5e77daf9847ffe252.tar.bz2
luaossl-fbc2058139566d2530d72ec5e77daf9847ffe252.zip
unbreak openssl.rand by fixing auxL_newlib bug
Diffstat (limited to 'src')
-rw-r--r--src/openssl.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/openssl.c b/src/openssl.c
index b539d87..c777e14 100644
--- a/src/openssl.c
+++ b/src/openssl.c
@@ -778,7 +778,7 @@ static inline size_t auxL_liblen(const auxL_Reg *l) {
lua_createtable((L), 0, countof((l)) - 1)
#define auxL_newlib(L, l, nups) \
- (auxL_newlibtable((L), (l)), auxL_setfuncs((L), (l), (nups)))
+ (auxL_newlibtable((L), (l)), lua_insert((L), -(nups + 1)), auxL_setfuncs((L), (l), (nups)))
static void auxL_setfuncs(lua_State *L, const auxL_Reg *l, int nups) {
for (; l->name; l++) {