diff options
author | Mario <mario@mariovavti.com> | 2021-05-26 18:02:29 +0000 |
---|---|---|
committer | Mario <mario@mariovavti.com> | 2021-05-26 18:02:29 +0000 |
commit | ff34a787c34c757b8959bbe51a485890e2345902 (patch) | |
tree | e19a342885b69e053f6956325a7daa7a5891ea6a /vendor/lukasreschke/id3parser/src | |
parent | 84c5f57d2243ff8aa335e37fd5c6cb1b6d64e7d1 (diff) | |
download | volse-hubzilla-ff34a787c34c757b8959bbe51a485890e2345902.tar.gz volse-hubzilla-ff34a787c34c757b8959bbe51a485890e2345902.tar.bz2 volse-hubzilla-ff34a787c34c757b8959bbe51a485890e2345902.zip |
php8: more id3 parser fixes
Diffstat (limited to 'vendor/lukasreschke/id3parser/src')
-rw-r--r-- | vendor/lukasreschke/id3parser/src/getID3/Tags/getid3_id3v1.php | 2 | ||||
-rw-r--r-- | vendor/lukasreschke/id3parser/src/getID3/Tags/getid3_id3v2.php | 8 |
2 files changed, 5 insertions, 5 deletions
diff --git a/vendor/lukasreschke/id3parser/src/getID3/Tags/getid3_id3v1.php b/vendor/lukasreschke/id3parser/src/getID3/Tags/getid3_id3v1.php index 18e850af1..944885b4f 100644 --- a/vendor/lukasreschke/id3parser/src/getID3/Tags/getid3_id3v1.php +++ b/vendor/lukasreschke/id3parser/src/getID3/Tags/getid3_id3v1.php @@ -39,7 +39,7 @@ class getid3_id3v1 extends getid3_handler // If second-last byte of comment field is null and last byte of comment field is non-null // then this is ID3v1.1 and the comment field is 28 bytes long and the 30th byte is the track number - if (($id3v1tag{125} === "\x00") && ($id3v1tag{126} !== "\x00")) { + if (($id3v1tag[125] === "\x00") && ($id3v1tag[126] !== "\x00")) { $ParsedID3v1['track'] = ord(substr($ParsedID3v1['comment'], 29, 1)); $ParsedID3v1['comment'] = substr($ParsedID3v1['comment'], 0, 28); } diff --git a/vendor/lukasreschke/id3parser/src/getID3/Tags/getid3_id3v2.php b/vendor/lukasreschke/id3parser/src/getID3/Tags/getid3_id3v2.php index a767a5e06..c1e982137 100644 --- a/vendor/lukasreschke/id3parser/src/getID3/Tags/getid3_id3v2.php +++ b/vendor/lukasreschke/id3parser/src/getID3/Tags/getid3_id3v2.php @@ -252,7 +252,7 @@ class getid3_id3v2 extends getid3_handler $thisfile_id3v2['padding']['length'] = strlen($framedata); $thisfile_id3v2['padding']['valid'] = true; for ($i = 0; $i < $thisfile_id3v2['padding']['length']; $i++) { - if ($framedata{$i} != "\x00") { + if ($framedata[$i] != "\x00") { $thisfile_id3v2['padding']['valid'] = false; $thisfile_id3v2['padding']['errorpos'] = $thisfile_id3v2['padding']['start'] + $i; $info['warning'][] = 'Invalid ID3v2 padding found at offset '.$thisfile_id3v2['padding']['errorpos'].' (the remaining '.($thisfile_id3v2['padding']['length'] - $i).' bytes are considered invalid)'; @@ -314,7 +314,7 @@ class getid3_id3v2 extends getid3_handler $len = strlen($framedata); for ($i = 0; $i < $len; $i++) { - if ($framedata{$i} != "\x00") { + if ($framedata[$i]!= "\x00") { $thisfile_id3v2['padding']['valid'] = false; $thisfile_id3v2['padding']['errorpos'] = $thisfile_id3v2['padding']['start'] + $i; $info['warning'][] = 'Invalid ID3v2 padding found at offset '.$thisfile_id3v2['padding']['errorpos'].' (the remaining '.($thisfile_id3v2['padding']['length'] - $i).' bytes are considered invalid)'; @@ -648,7 +648,7 @@ class getid3_id3v2 extends getid3_handler //unset($parsedFrame['data']); do not unset, may be needed elsewhere, e.g. for replaygain - } elseif ($parsedFrame['frame_name']{0} == 'T') { // 4.2. T??[?] Text information frame + } elseif ($parsedFrame['frame_name'][0] == 'T') { // 4.2. T??[?] Text information frame // There may only be one text information frame of its kind in an tag. // <Header for 'Text information frame', ID: 'T000' - 'TZZZ', // excluding 'TXXX' described in 4.2.6.> @@ -750,7 +750,7 @@ class getid3_id3v2 extends getid3_handler unset($parsedFrame['data']); - } elseif ($parsedFrame['frame_name']{0} == 'W') { // 4.3. W??? URL link frames + } elseif ($parsedFrame['frame_name'][0] == 'W') { // 4.3. W??? URL link frames // There may only be one URL link frame of its kind in a tag, // except when stated otherwise in the frame description // <Header for 'URL link frame', ID: 'W000' - 'WZZZ', excluding 'WXXX' |