Bug 857831 - Remove WBMP content sniffer. r=jmuizelaar

This commit is contained in:
Shih-Chiang Chien 2013-04-11 07:48:09 -04:00
parent 7a5a9aa203
commit e142faf203

View File

@ -2041,16 +2041,6 @@ nsresult imgLoader::GetMimeTypeFromContent(const char* aContents, uint32_t aLeng
aContentType.AssignLiteral(IMAGE_ICO);
}
#ifdef MOZ_WBMP
// A well-defined type 0 WBMP file starts with an "0000 0000b" byte followed
// by an "0xx0 0000b" byte (x = don't care).
else if (aLength >= 2 && (static_cast<unsigned char>(aContents[0]) == 0x00 &&
(static_cast<unsigned char>(aContents[1]) & 0x9F) == 0x00))
{
aContentType.AssignLiteral(IMAGE_WBMP);
}
#endif
else {
/* none of the above? I give up */
return NS_ERROR_NOT_AVAILABLE;