Warnings as errors fix

git-svn-id: http://skia.googlecode.com/svn/trunk@11250 2bbb7eff-a529-9590-31e7-b0007b416f81
This commit is contained in:
robertphillips@google.com 2013-09-13 12:54:33 +00:00
parent 4b681bc95b
commit 558d5d3f08
2 changed files with 3 additions and 3 deletions

View File

@ -296,7 +296,7 @@ void SkOrderedWriteBuffer::writeFlattenable(SkFlattenable* flattenable) {
const char* name = SkFlattenable::FactoryToName(factory);
this->writeString(name);
if (NULL == name) {
SkASSERT(!"Missing factory name");
SkASSERT(0); // Missing factory name
return;
}
} else if (fFactorySet) {

View File

@ -24,8 +24,8 @@ SkMorphologyImageFilter::SkMorphologyImageFilter(SkFlattenableReadBuffer& buffer
: INHERITED(buffer) {
fRadius.fWidth = buffer.readInt();
fRadius.fHeight = buffer.readInt();
buffer.validate(SkScalarIsFinite(fRadius.fWidth) &&
SkScalarIsFinite(fRadius.fHeight) &&
buffer.validate(SkScalarIsFinite(SkIntToScalar(fRadius.fWidth)) &&
SkScalarIsFinite(SkIntToScalar(fRadius.fHeight)) &&
(fRadius.fWidth >= 0) &&
(fRadius.fHeight >= 0));
}