Skip to content

Commit

Permalink
JamesHeinrich#442 Warning on PrintHexBytes function when $string is n…
Browse files Browse the repository at this point in the history
…ot a string

JamesHeinrich#442
  • Loading branch information
JamesHeinrich committed Apr 26, 2024
1 parent 143af33 commit 1192b61
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion getid3/getid3.php
Original file line number Diff line number Diff line change
Expand Up @@ -387,7 +387,7 @@ class getID3
*/
protected $startup_warning = '';

const VERSION = '1.9.23-202403260825';
const VERSION = '1.9.23-202404261550';
const FREAD_BUFFER_SIZE = 32768;

const ATTACHMENTS_NONE = false;
Expand Down
8 changes: 4 additions & 4 deletions getid3/module.audio-video.quicktime.php
Original file line number Diff line number Diff line change
Expand Up @@ -2122,7 +2122,7 @@ public function QuicktimeParseAtom($atomname, $atomsize, $atom_data, $baseoffset
$atom_structure['ES_DescrTag'] = getid3_lib::BigEndian2Int(substr($atom_data, $esds_offset, 1));
$esds_offset += 1;
if ($atom_structure['ES_DescrTag'] != 0x03) {
$this->warning('expecting esds.ES_DescrTag = 0x03, found 0x'.getid3_lib::PrintHexBytes($atom_structure['ES_DescrTag']).'), at offset '.$atom_structure['offset']);
$this->warning('expecting esds.ES_DescrTag = 0x03, found 0x'.sprintf('%02X', $atom_structure['ES_DescrTag']).', at offset '.$atom_structure['offset']);
break;
}
$atom_structure['ES_DescrSize'] = $this->quicktime_read_mp4_descr_length($atom_data, $esds_offset);
Expand Down Expand Up @@ -2151,7 +2151,7 @@ public function QuicktimeParseAtom($atomname, $atomsize, $atom_data, $baseoffset
$atom_structure['ES_DecoderConfigDescrTag'] = getid3_lib::BigEndian2Int(substr($atom_data, $esds_offset, 1));
$esds_offset += 1;
if ($atom_structure['ES_DecoderConfigDescrTag'] != 0x04) {
$this->warning('expecting esds.ES_DecoderConfigDescrTag = 0x04, found 0x'.getid3_lib::PrintHexBytes($atom_structure['ES_DecoderConfigDescrTag']).'), at offset '.$atom_structure['offset']);
$this->warning('expecting esds.ES_DecoderConfigDescrTag = 0x04, found 0x'.sprintf('%02X', $atom_structure['ES_DecoderConfigDescrTag']).', at offset '.$atom_structure['offset']);
break;
}
$atom_structure['ES_DecoderConfigDescrTagSize'] = $this->quicktime_read_mp4_descr_length($atom_data, $esds_offset);
Expand Down Expand Up @@ -2182,7 +2182,7 @@ public function QuicktimeParseAtom($atomname, $atomsize, $atom_data, $baseoffset
$atom_structure['ES_DecSpecificInfoTag'] = getid3_lib::BigEndian2Int(substr($atom_data, $esds_offset, 1));
$esds_offset += 1;
if ($atom_structure['ES_DecSpecificInfoTag'] != 0x05) {
$this->warning('expecting esds.ES_DecSpecificInfoTag = 0x05, found 0x'.getid3_lib::PrintHexBytes($atom_structure['ES_DecSpecificInfoTag']).'), at offset '.$atom_structure['offset']);
$this->warning('expecting esds.ES_DecSpecificInfoTag = 0x05, found 0x'.sprintf('%02X', $atom_structure['ES_DecSpecificInfoTag']).', at offset '.$atom_structure['offset']);
break;
}
$atom_structure['ES_DecSpecificInfoTagSize'] = $this->quicktime_read_mp4_descr_length($atom_data, $esds_offset);
Expand All @@ -2193,7 +2193,7 @@ public function QuicktimeParseAtom($atomname, $atomsize, $atom_data, $baseoffset
$atom_structure['ES_SLConfigDescrTag'] = getid3_lib::BigEndian2Int(substr($atom_data, $esds_offset, 1));
$esds_offset += 1;
if ($atom_structure['ES_SLConfigDescrTag'] != 0x06) {
$this->warning('expecting esds.ES_SLConfigDescrTag = 0x05, found 0x'.getid3_lib::PrintHexBytes($atom_structure['ES_SLConfigDescrTag']).'), at offset '.$atom_structure['offset']);
$this->warning('expecting esds.ES_SLConfigDescrTag = 0x05, found 0x'.sprintf('%02X', $atom_structure['ES_SLConfigDescrTag']).', at offset '.$atom_structure['offset']);
break;
}
$atom_structure['ES_SLConfigDescrTagSize'] = $this->quicktime_read_mp4_descr_length($atom_data, $esds_offset);
Expand Down

0 comments on commit 1192b61

Please sign in to comment.