forked from Archive/PX4-Autopilot
Add functions for initializing empty crypto backend handles
Signed-off-by: Jukka Laitinen <jukkax@ssrc.tii.ae>
This commit is contained in:
parent
9290ea974e
commit
aa61bc4942
|
@ -37,6 +37,5 @@ typedef struct {
|
|||
int handle;
|
||||
} keystore_session_handle_t;
|
||||
|
||||
/* For the stub_keystore the handle is not used at the moment, so it is always valid */
|
||||
|
||||
inline bool keystore_session_handle_valid(keystore_session_handle_t handle) {return handle.handle > 0;}
|
||||
static inline void keystore_session_handle_init(keystore_session_handle_t *handle) {handle->handle = 0;}
|
||||
static inline bool keystore_session_handle_valid(keystore_session_handle_t handle) {return handle.handle > 0;}
|
||||
|
|
|
@ -43,4 +43,5 @@ typedef struct {
|
|||
keystore_session_handle_t keystore_handle;
|
||||
} crypto_session_handle_t;
|
||||
|
||||
static inline void crypto_session_handle_init(crypto_session_handle_t *handle) {handle->handle = 0;}
|
||||
static inline bool crypto_session_handle_valid(crypto_session_handle_t handle) {return handle.handle > 0;}
|
||||
|
|
Loading…
Reference in New Issue