Closed Bug 1657311 Opened 4 years ago Closed 4 years ago

Hard-code MIME-extension mappings for FLAC and AAC

Categories

(Firefox :: File Handling, enhancement)

enhancement

Tracking

()

VERIFIED FIXED
81 Branch
Tracking Status
firefox81 --- verified

People

(Reporter: evilpie, Assigned: evilpie)

References

(Blocks 2 open bugs)

Details

Attachments

(1 file)

Looking at the nsExtraMimeTypeEntry array I think FLAC and AAC are two obvious additions that could be made. For both I looked up the appropriate extension on Wikipedia. For FLAC there was only a single extension .flac, that I have personally encountered so that seems fine. For AAC wikipedia lists various container formats etc. I chose just .aac for the audio format.

Per spec we should only determine what a type is through sniffing ; not using the file typename.

I think this is basically outside spec territory. We use this list for various cases where we don't sniff. There is no good reason to not add these specific MIME types here, when we already support most other image, video and audio MIME types anyway.

Pushed by evilpies@gmail.com:
https://hg.mozilla.org/integration/autoland/rev/df7c9cae79be
Hard-code MIME-extension mappings for FLAC and AAC. r=jya,Gijs
Status: NEW → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → 81 Branch

The FLAC part is verified with 81.0a1 (2020-08-10).

However, for AAC; as far as I can see it saves files as mp4 on Windows 10.
Tried with 1; 2; or is it intended on Windows-OS?

Flags: needinfo?(evilpies)

These files seem to have an .mp4 file extension. I am not sure how we decide to display the description, but mp4 files are containers and can contain any kind of audio/video.

https://docs.espressif.com/projects/esp-adf/en/latest/design-guide/audio-samples.html seems to have AAC files with the .aac extension that we are handling.

Flags: needinfo?(evilpies)

You are right, thank you for the input!
Confirmed for AAC as well.

Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: