mirror of
https://github.com/espressif/esp-idf.git
synced 2025-08-09 04:25:32 +00:00
components/openssl: optimize the SSL certification and private key function
1. add inheritance function 2. remove low-level platform unload cert & pkey function 3. optimize the cert load and free function
This commit is contained in:
@@ -69,14 +69,12 @@
|
||||
#define IMPLEMENT_X509_METHOD(func_name, \
|
||||
new, \
|
||||
free, \
|
||||
load, \
|
||||
unload) \
|
||||
load) \
|
||||
const X509_METHOD* func_name(void) { \
|
||||
static const X509_METHOD func_name##_data LOCAL_ATRR = { \
|
||||
new, \
|
||||
free, \
|
||||
load, \
|
||||
unload, \
|
||||
load \
|
||||
}; \
|
||||
return &func_name##_data; \
|
||||
}
|
||||
@@ -84,14 +82,12 @@
|
||||
#define IMPLEMENT_PKEY_METHOD(func_name, \
|
||||
new, \
|
||||
free, \
|
||||
load, \
|
||||
unload) \
|
||||
load) \
|
||||
const PKEY_METHOD* func_name(void) { \
|
||||
static const PKEY_METHOD func_name##_data LOCAL_ATRR = { \
|
||||
new, \
|
||||
free, \
|
||||
load, \
|
||||
unload, \
|
||||
load \
|
||||
}; \
|
||||
return &func_name##_data; \
|
||||
}
|
||||
|
Reference in New Issue
Block a user