Bug 78906 - jpeg images not loading. r=pavlov, sr=blizzard

This commit is contained in:
tor%cs.brown.edu 2001-05-04 20:05:49 +00:00
parent 3d11fc509c
commit 3447e15d9b

View File

@ -258,7 +258,7 @@ NS_IMETHODIMP nsJPEGDecoder::WriteFrom(nsIInputStream *inStr, PRUint32 count, PR
mObserver->OnStartDecode(nsnull, nsnull);
/* we only support jpegs with 1 or 3 components currently. */
if (mInfo.output_components != 1 ||
if (mInfo.output_components != 1 &&
mInfo.output_components != 3) {
mState = JPEG_ERROR;
return NS_ERROR_UNEXPECTED;