[libbluray-devel] Log failed data type
hpi1
git at videolan.org
Thu Nov 6 12:59:26 CET 2014
libbluray | branch: master | hpi1 <hpi1 at anonymous.org> | Thu Nov 6 13:58:08 2014 +0200| [984fbfa718602c47536f763b6db37305d09b7fb5] | committer: hpi1
Log failed data type
> http://git.videolan.org/gitweb.cgi/libbluray.git/?a=commit;h=984fbfa718602c47536f763b6db37305d09b7fb5
---
src/file/libaacs.c | 15 ++++++++++++++-
1 file changed, 14 insertions(+), 1 deletion(-)
diff --git a/src/file/libaacs.c b/src/file/libaacs.c
index 33d4cfa..af41983 100644
--- a/src/file/libaacs.c
+++ b/src/file/libaacs.c
@@ -266,10 +266,23 @@ uint32_t libaacs_get_mkbv(BD_AACS *p)
return p ? p->mkbv : 0;
}
+static const char *_type2str(int type)
+{
+ switch (type) {
+ case BD_AACS_DISC_ID: return "DISC_ID";
+ case BD_AACS_MEDIA_VID: return "MEDIA_VID";
+ case BD_AACS_MEDIA_PMSN: return "MEDIA_PMSN";
+ case BD_AACS_DEVICE_BINDING_ID: return "DEVICE_BINDING_ID";
+ case BD_AACS_DEVICE_NONCE: return "DEVICE_NONCE";
+ case BD_AACS_MEDIA_KEY: return "MEDIA_KEY";
+ default: return "???";
+ }
+}
+
BD_PRIVATE const uint8_t *libaacs_get_aacs_data(BD_AACS *p, int type)
{
if (!p || !p->aacs) {
- BD_DEBUG(DBG_BLURAY | DBG_CRIT, "get_aacs_data(): libaacs not initialized!\n");
+ BD_DEBUG(DBG_BLURAY | DBG_CRIT, "get_aacs_data(%s): libaacs not initialized!\n", _type2str(type));
return NULL;
}
More information about the libbluray-devel
mailing list