Rework OMEMO handling on disconnect

* Fix missing destruction of `session_store` and mutex
* Replace `glib_hash_table_free()`
  The glib API `g_hash_table_destroy()` does exactly the same.
* Use the default libsignal `destroy_func` instead of doing that manually
* Set internal state to `0` after everything is cleaned up

Signed-off-by: Steffen Jaeckel <jaeckel-floss@eyet-services.de>
This commit is contained in:
Steffen Jaeckel
2023-11-16 13:24:17 +01:00
parent 835ea397ac
commit fdfe3e2ad9
5 changed files with 44 additions and 51 deletions

View File

@@ -51,8 +51,6 @@ typedef enum {
PROF_OMEMOPOLICY_ALWAYS
} prof_omemopolicy_t;
typedef struct omemo_context_t omemo_context;
typedef struct omemo_key
{
unsigned char* data;