Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
EIT: Fix possible wrong memory access in _eit_process_event()
  • Loading branch information
perexg committed Apr 22, 2015
1 parent 7749976 commit bfec4e7
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/epggrab/module/eit.c
Expand Up @@ -446,13 +446,14 @@ static int _eit_process_event
int r;
dtag = ptr[0];
dlen = ptr[1];
tvhtrace(mod->id, " dtag %02X dlen %d", dtag, dlen);
tvhlog_hexdump(mod->id, ptr+2, dlen);

dllen -= 2;
ptr += 2;
if (dllen < dlen) break;

tvhtrace(mod->id, " dtag %02X dlen %d", dtag, dlen);
tvhlog_hexdump(mod->id, ptr, dlen);

switch (dtag) {
case DVB_DESC_SHORT_EVENT:
r = _eit_desc_short_event(mod, ptr, dlen, &ev);
Expand Down

0 comments on commit bfec4e7

Please sign in to comment.