Check negative width before blitAntiRect
Since we decrease the width when clipped, it might be negative. Bug: skia:7858 Change-Id: I348bd07d917905a55bec1a4b4e0915c6528fe6b1 Reviewed-on: https://skia-review.googlesource.com/123927 Auto-Submit: Yuqian Li <liyuqian@google.com> Reviewed-by: Mike Klein <mtklein@google.com> Commit-Queue: Yuqian Li <liyuqian@google.com>
This commit is contained in:
parent
abc8575380
commit
c79e2d1551
@ -147,7 +147,9 @@ void SkBlitter::blitCoverageDeltas(SkCoverageDeltaList* deltas, const SkIRect& c
|
||||
height -= botOverClip;
|
||||
}
|
||||
|
||||
this->blitAntiRect(rectX, rectY, width, height, leftAlpha, rightAlpha);
|
||||
if (width >= 0) {
|
||||
this->blitAntiRect(rectX, rectY, width, height, leftAlpha, rightAlpha);
|
||||
}
|
||||
y += antiRect.fHeight - 1; // -1 because ++y in the for loop
|
||||
continue;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user