[libbluray-devel] split libaacs_unload()
npzacs
git at videolan.org
Sun Jan 31 12:55:34 CET 2016
libbluray | branch: master | npzacs <npzacs at gmail.com> | Sun Jan 31 13:42:09 2016 +0200| [2ded00f5e0aa894b40b17611d2925d352358407c] | committer: npzacs
split libaacs_unload()
> http://git.videolan.org/gitweb.cgi/libbluray.git/?a=commit;h=2ded00f5e0aa894b40b17611d2925d352358407c
---
src/libbluray/disc/aacs.c | 16 ++++++++++------
1 file changed, 10 insertions(+), 6 deletions(-)
diff --git a/src/libbluray/disc/aacs.c b/src/libbluray/disc/aacs.c
index 3059d66..d21b27e 100644
--- a/src/libbluray/disc/aacs.c
+++ b/src/libbluray/disc/aacs.c
@@ -58,15 +58,19 @@ static void _libaacs_close(BD_AACS *p)
}
}
-void libaacs_unload(BD_AACS **p)
+static void _unload(BD_AACS *p)
{
- if (p && *p) {
- _libaacs_close(*p);
+ _libaacs_close(p);
- if ((*p)->h_libaacs) {
- dl_dlclose((*p)->h_libaacs);
- }
+ if (p->h_libaacs) {
+ dl_dlclose(p->h_libaacs);
+ }
+}
+void libaacs_unload(BD_AACS **p)
+{
+ if (p && *p) {
+ _unload(*p);
X_FREE(*p);
}
}
More information about the libbluray-devel
mailing list