fix -Wsign-conversion warnings

This commit is contained in:
Dane Springmeyer 2013-11-03 15:36:21 -08:00
parent d9bc3dbb81
commit a5f8ba5c6c

View file

@ -134,9 +134,9 @@ public:
inline unsigned rgba() const
{
#ifdef MAPNIK_BIG_ENDIAN
return (alpha_) | (blue_ << 8) | (green_ << 16) | (red_ << 24) ;
return static_cast<unsigned>((alpha_) | (blue_ << 8) | (green_ << 16) | (red_ << 24)) ;
#else
return (alpha_ << 24) | (blue_ << 16) | (green_ << 8) | (red_) ;
return static_cast<unsigned>((alpha_ << 24) | (blue_ << 16) | (green_ << 8) | (red_)) ;
#endif
}
};