mpeg-2 detected as tga (Targa image)

Bug #1809014 reported by Finn Kempers
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
file (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

It appears that currently using either the file command or through the File::LibMagic interface that 1:5.34-2 on Cosmic (18.10) makes a MPEG-2 file be detected as Targa at a higher priority, thus taking precedence over being what it actually is. See the below lines as examples using clips from http://hubblesource.stsci.edu/sources/video/clips/ as examples:

$ file -k /home/piratefinn/Downloads/hst_2.mpg
/home/piratefinn/Downloads/hst_2.mpg: Targa image data - Map 63635 x 65536 x 1 +268 +60928 - 11-bit alpha - top - right - four way interleave MPEG sequence, v2, program multiplex (Lepton 3.x), scale 0-0, spot sensor temperature 0.000000, unit celsius, color scheme 0, calibration: offset 0.000000, slope 0.000000\012- data

Note that this appears to only affect MPEG-2 (and possibly higher) as MPEG-1 is detected corretly.

$ file -k /home/piratefinn/Downloads/hst_1.mpg
/home/piratefinn/Downloads/hst_1.mpg: MPEG sequence, v1, progressive Y'CbCr 4:2:0 video, 320x240, 4:3, 29.97 fps (Lepton 2.x), scale 1-2, spot sensor temperature 0.000000, unit celsius, color scheme 0, show spot sensor, show scale bar, maximum point enabled, calibration: offset 586.228088, slope -411899156202779801569722368.000000\012- data
file -k /home/piratefinn/Downloads/hst_1.mpg

This appears to not be an issue in 1:5.25 used in 16.04, however looking through the github it appears since then in possible 5.26 (or above) changes as seen in https://github.com/file/file/commit/aee048a020badb5f36008f6d11e7d5b32834bcb2 affected this.

Tags: cosmic
Juhani Numminen (jsonic)
tags: added: cosmic
Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in file (Ubuntu):
status: New → Confirmed
Revision history for this message
Nicolas_Raoul (nicolas-raoul) wrote :

Problem present in upstream (Debian)

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.