Bug 513681 - part 1 - fix a few warnings.r=joe,a=blocker
authorBobby Holley <bobbyholley@gmail.com>
Fri, 13 Aug 2010 18:15:20 -0400
changeset 51191 ba16605752098bfb2805bf1f26bfe6f2b8973c63
parent 51190 3aeb7495b4f15b892162932c65f22fb4daf0364f
child 51192 bdaed1b28b382e62c433e5d08a64101ee092c52e
push idunknown
push userunknown
push dateunknown
reviewersjoe, blocker
bugs513681
milestone2.0b5pre
Bug 513681 - part 1 - fix a few warnings.r=joe,a=blocker
modules/libpr0n/decoders/png/nsPNGDecoder.cpp
modules/libpr0n/src/imgRequest.cpp
--- a/modules/libpr0n/decoders/png/nsPNGDecoder.cpp
+++ b/modules/libpr0n/decoders/png/nsPNGDecoder.cpp
@@ -771,17 +771,17 @@ row_callback(png_structp png_ptr, png_by
    */
   nsPNGDecoder *decoder =
                static_cast<nsPNGDecoder*>(png_get_progressive_ptr(png_ptr));
 
   // skip this frame
   if (decoder->mFrameIsHidden)
     return;
 
-  if (row_num >= decoder->mFrameRect.height)
+  if (row_num >= (png_uint_32) decoder->mFrameRect.height)
     return;
 
   if (new_row) {
     PRInt32 width = decoder->mFrameRect.width;
     PRUint32 iwidth = decoder->mFrameRect.width;
 
     png_bytep line = new_row;
     if (decoder->interlacebuf) {
--- a/modules/libpr0n/src/imgRequest.cpp
+++ b/modules/libpr0n/src/imgRequest.cpp
@@ -955,17 +955,17 @@ NS_IMETHODIMP imgRequest::OnDataAvailabl
         return NS_BINDING_ABORTED;
       }
 
       LOG_MSG(gImgLog, "imgRequest::OnDataAvailable", "Got content type from the channel");
     }
 
     /* now we have mimetype, so we can infer the image type that we want */
     imageType = mContentType.EqualsLiteral(SVG_MIMETYPE) ?
-      imgIContainer::TYPE_VECTOR : imgIContainer::TYPE_RASTER;
+      (PRUint16) imgIContainer::TYPE_VECTOR : (PRUint16) imgIContainer::TYPE_RASTER;
 
     /* set our mimetype as a property */
     nsCOMPtr<nsISupportsCString> contentType(do_CreateInstance("@mozilla.org/supports-cstring;1"));
     if (contentType) {
       contentType->SetData(mContentType);
       mProperties->Set("type", contentType);
     }