net::GetExtensionsForMimeType() returns wrong results with prefix matching |
||
Issue description
net::GetExtensionsForMimeType() returns wrong results due to prefix matching of MIME type strings.
For example:
- net::GetExtensionsForMimeType("image/b") -> "bmp"
- net::GetExtensionsForMimeType("") -> [all known extensions]
,
Jan 31 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/f6ef68261dc24e0500a99439575fdd9feeb712a6 commit f6ef68261dc24e0500a99439575fdd9feeb712a6 Author: eroman <eroman@chromium.org> Date: Tue Jan 31 19:12:02 2017 Don't blindly do a prefix match when evaluating net::GetExtensionsForMimeType(). BUG= 685932 Review-Url: https://codereview.chromium.org/2665953002 Cr-Commit-Position: refs/heads/master@{#447290} [modify] https://crrev.com/f6ef68261dc24e0500a99439575fdd9feeb712a6/net/base/mime_util.cc [modify] https://crrev.com/f6ef68261dc24e0500a99439575fdd9feeb712a6/net/base/mime_util_unittest.cc
,
Jan 31 2017
,
Feb 1 2017
eroman: Thanks for the fix! |
||
►
Sign in to add a comment |
||
Comment 1 by eroman@chromium.org
, Jan 30 2017Owner: eroman@chromium.org
Status: Assigned (was: Untriaged)