diff options
author | Stef Walter <stef@thewalter.net> | 2014-06-25 10:55:10 +0200 |
---|---|---|
committer | Stef Walter <stef@thewalter.net> | 2014-06-25 10:58:37 +0200 |
commit | 6527f5d3b24a96369a24281db7593d5c4fc73408 (patch) | |
tree | 006bf9345c04523a763d6acd780c01a165f2add7 | |
parent | d21967cdcd18c8fcb749f874c492b7f6c4965817 (diff) |
p11-kit: Fix corrupted list when initialization of modules fail
This fixes the function call p11_kit_module_initialize() to
correctly rearrange the modules array when initializing a module
fails.
Also fixes p11_kit_modules_load_and_initialize()
-rw-r--r-- | p11-kit/modules.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/p11-kit/modules.c b/p11-kit/modules.c index b373544..2988f31 100644 --- a/p11-kit/modules.c +++ b/p11-kit/modules.c @@ -1985,6 +1985,8 @@ p11_kit_modules_initialize (CK_FUNCTION_LIST **modules, failure_callback (modules[i]); out--; free (name); + } else { + modules[out] = modules[i]; } } |