Handle zero-scale factors in InverseMapRect

SkMatrix::isScaleTranslate() returns true when sx or sy are 0, which
is technically valid. InverseMapRect was implemented assuming sx,sy !=0
(like rectStaysRect() implies).

Bug: oss-fuzz:58474
Change-Id: I81ea49b4c86138656f7b01c7eb1c2587c8a90822
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/696477
Commit-Queue: Jim Van Verth <jvanverth@google.com>
Auto-Submit: Michael Ludwig <michaelludwig@google.com>
Reviewed-by: Jim Van Verth <jvanverth@google.com>
2 files changed