mirror of
https://github.com/brunoos/luasec.git
synced 2024-12-26 20:48:22 +01:00
Code format
This commit is contained in:
parent
c9539bca86
commit
f22b3ea609
@ -689,11 +689,10 @@ static int meth_exportkeyingmaterial(lua_State *L)
|
||||
size_t contextlen = 0;
|
||||
const unsigned char *context = NULL;
|
||||
|
||||
if(!lua_isnoneornil(L, 4)) {
|
||||
context = (unsigned char *)luaL_checklstring(L, 4, &contextlen);
|
||||
}
|
||||
if (!lua_isnoneornil(L, 4))
|
||||
context = (unsigned char*)luaL_checklstring(L, 4, &contextlen);
|
||||
|
||||
/* temporary buffer memory-managed by Lua itself */
|
||||
/* Temporary buffer memory-managed by Lua itself */
|
||||
unsigned char *out = lua_newuserdata(L, olen);
|
||||
|
||||
if(SSL_export_keying_material(ssl->ssl, out, olen, label, llen, context, contextlen, context != NULL) != 1) {
|
||||
@ -703,7 +702,7 @@ static int meth_exportkeyingmaterial(lua_State *L)
|
||||
return 2;
|
||||
}
|
||||
|
||||
lua_pushlstring(L, (char *)out, olen);
|
||||
lua_pushlstring(L, (char*)out, olen);
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user