Index: include/core/SkCanvas.h |
diff --git a/include/core/SkCanvas.h b/include/core/SkCanvas.h |
index 60f93029f66617fa698ddd91fc41cef8a30f8828..a726c44ef6f1feb0dad85d0d443530271b72da67 100644 |
--- a/include/core/SkCanvas.h |
+++ b/include/core/SkCanvas.h |
@@ -707,6 +707,10 @@ public: |
@param paint The paint used to draw the region |
*/ |
void drawRegion(const SkRegion& region, const SkPaint& paint) { |
+ if (region.isEmpty()) { |
+ return; |
+ } |
+ |
this->onDrawRegion(region, paint); |
} |