check if scconf_find_blocks returns NULL;

git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@2710 c6295689-39f2-0310-b995-f0e70906c6a9
This commit is contained in:
aj 2005-12-05 21:36:26 +00:00
parent 7e15333537
commit 2a1c6cb87e
1 changed files with 2 additions and 0 deletions

View File

@ -1220,6 +1220,8 @@ scconf_block *_get_conf_block(sc_context_t *ctx, const char *name1, const char *
scconf_block **blocks;
blocks = scconf_find_blocks(ctx->conf, ctx->conf_blocks[i], name1, name2);
if (!blocks)
return NULL;
conf_block = blocks[0];
free(blocks);
if (conf_block != NULL && priority)