1
0
mirror of https://github.com/nmap/nmap.git synced 2025-12-31 11:59:03 +00:00

Remove an unused parameter to pkey_type_to_string and fix its documentation. Patch by Matt Selsky.

This commit is contained in:
david
2010-10-20 15:48:14 +00:00
parent 7b9b094ea5
commit 274d5ccca3

View File

@@ -373,8 +373,8 @@ static void cert_pem_to_string(lua_State *L, X509 *cert)
}
/* This is a helper function for l_get_ssl_certificate. It converts the
public-key type to a string on the stack. */
static const char *pkey_type_to_string(lua_State *L, int type)
public-key type to a string. */
static const char *pkey_type_to_string(int type)
{
switch (type) {
case EVP_PKEY_RSA:
@@ -430,7 +430,7 @@ int l_get_ssl_certificate(lua_State *L)
pubkey = X509_get_pubkey(cert);
lua_newtable(L);
lua_pushstring(L, pkey_type_to_string(L, pubkey->type));
lua_pushstring(L, pkey_type_to_string(pubkey->type));
lua_setfield(L, -2, "type");
lua_pushnumber(L, EVP_PKEY_bits(pubkey));
lua_setfield(L, -2, "bits");