[1.9.4b1] Analyze GIF detects TS

Locked
Pernod
getID3() contributor
Posts: 103
Joined: Sat Mar 21, 2009 5:30 pm
Are you a spambot?: no
Location: London, UK
Contact:

[1.9.4b1] Analyze GIF detects TS

Post by Pernod » Tue Jan 29, 2013 1:00 am

Analyzing any GIF file will be detected as a TS. This is caused by the pattern to match a TS file in GetFileFormatsArray() being too vague.

TS: 'pattern' => '^\x47'
GIF: 'pattern' => '^GIF'

Hex &47 = 'G' so matches TS before being tested for GIF.

James Heinrich
getID3() v1 developer
Posts: 1457
Joined: Fri May 04, 2001 4:00 pm
Are you a spambot?: no
Location: Northern Ontario, Canada
Contact:

Re: [1.9.4b1] Analyze GIF detects TS

Post by James Heinrich » Tue Jan 29, 2013 1:11 am

Thanks. Please update the pattern in getid3.php (around line 899). Change

Code: Select all

'pattern'   => '^\x47'
to

Code: Select all

'pattern'   => '^(\x47.{187}){10,}'
Fix will be included in v1.9.5.

Pernod
getID3() contributor
Posts: 103
Joined: Sat Mar 21, 2009 5:30 pm
Are you a spambot?: no
Location: London, UK
Contact:

Re: [1.9.4b1] Analyze GIF detects TS

Post by Pernod » Tue Jan 29, 2013 1:25 am

Thanks for the prompt fix.

James Heinrich
getID3() v1 developer
Posts: 1457
Joined: Fri May 04, 2001 4:00 pm
Are you a spambot?: no
Location: Northern Ontario, Canada
Contact:

Re: [1.9.4b1] Analyze GIF detects TS

Post by James Heinrich » Wed Feb 20, 2013 9:11 pm

Fix included in v1.9.5

Locked