check if scconf_find_blocks returned NULL.
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@2713 c6295689-39f2-0310-b995-f0e70906c6a9
This commit is contained in:
parent
d7b6abaef5
commit
686297304a
|
@ -618,7 +618,7 @@ int sc_pkcs15_bind(sc_card_t *card,
|
|||
for (i = 0; ctx->conf_blocks[i] != NULL; i++) {
|
||||
blocks = scconf_find_blocks(ctx->conf, ctx->conf_blocks[i],
|
||||
"framework", "pkcs15");
|
||||
if (blocks[0] != NULL)
|
||||
if (blocks && blocks[0] != NULL)
|
||||
conf_block = blocks[0];
|
||||
free(blocks);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue