Skip to content

Commit

Permalink
Do not break on missing hdlr box
Browse files Browse the repository at this point in the history
  • Loading branch information
Phencys committed Sep 16, 2024
1 parent 226213d commit b18b71b
Showing 1 changed file with 14 additions and 1 deletion.
15 changes: 14 additions & 1 deletion HbbTV_DVB/impl/commonDVBValidation.php
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,20 @@
}

// Segment part
$hdlrType = $xmlRepresentation->getElementsByTagName('hdlr')->item(0)->getAttribute('handler_type');
$hdlrBoxes = $xmlRepresentation->getElementsByTagName('hdlr');
$logger->test(
"HbbTV-DVB DASH Validation Requirements",
"Conformance-Internal",
"Representation is expected to contain (at least one) `hdlr` box",
count($hdlrBoxes),
"WARN",
"`hdlr` box found",
"No `hdlr` box found, skipping further checks"
);
if (!count($hdlrBoxes)) {
return;
}
$hdlrType = $hdlrBoxes->item(0)->getAttribute('handler_type');
$sdType = $xmlRepresentation->getElementsByTagName("$hdlrType" . '_sampledescription')->item(0)->getAttribute('sdType');


Expand Down

0 comments on commit b18b71b

Please sign in to comment.