[libbluray-devel] Log unknown BDJ events.
hpi1
git at videolan.org
Mon May 16 13:58:03 CEST 2016
libbluray | branch: master | hpi1 <hpi1 at anonymous.org> | Mon May 16 14:56:01 2016 +0300| [103f9216d8ab93fcbca4e43f4e191f826dee72c1] | committer: hpi1
Log unknown BDJ events.
Avoid array out of bounds access.
> http://git.videolan.org/gitweb.cgi/libbluray.git/?a=commit;h=103f9216d8ab93fcbca4e43f4e191f826dee72c1
---
src/libbluray/bdj/bdj.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/src/libbluray/bdj/bdj.c b/src/libbluray/bdj/bdj.c
index 6e87f96..3a4446d 100644
--- a/src/libbluray/bdj/bdj.c
+++ b/src/libbluray/bdj/bdj.c
@@ -715,8 +715,11 @@ int bdj_process_event(BDJAVA *bdjava, unsigned ev, unsigned param)
return -1;
}
+ if (ev > BD_EVENT_LAST) {
+ BD_DEBUG(DBG_BDJ | DBG_CRIT, "bdj_process_event(%d,%d): unknown event\n", ev, param);
+ }
// Disable too verbose logging (PTS)
- if (ev != BDJ_EVENT_PTS) {
+ else if (ev != BDJ_EVENT_PTS) {
BD_DEBUG(DBG_BDJ, "bdj_process_event(%s,%d)\n", ev_name[ev], param);
}
More information about the libbluray-devel
mailing list