close files when the context is destroyed
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@2001 c6295689-39f2-0310-b995-f0e70906c6a9
This commit is contained in:
parent
56a37d6c48
commit
5feb1f133f
@ -621,7 +621,10 @@ int sc_release_context(struct sc_context *ctx)
|
|||||||
if (drv->dll)
|
if (drv->dll)
|
||||||
scdl_close(drv->dll);
|
scdl_close(drv->dll);
|
||||||
}
|
}
|
||||||
ctx->debug_file = ctx->error_file = NULL;
|
if (ctx->debug_file)
|
||||||
|
fclose(ctx->debug_file);
|
||||||
|
if (ctx->error_file)
|
||||||
|
fclose(ctx->error_file);
|
||||||
if (ctx->preferred_language)
|
if (ctx->preferred_language)
|
||||||
free(ctx->preferred_language);
|
free(ctx->preferred_language);
|
||||||
if (ctx->conf)
|
if (ctx->conf)
|
||||||
|
Loading…
Reference in New Issue
Block a user