Fix truncated webp images DO NOT MERGE

Bug: b/65290323
Test: ag/2974889

Merged-In: Ib6f385766d6d46ed7fe56188cae5a71b100102bd
Merged-In: I0cba5ab639f1e66b7c493a9f63735a0f5edbcfbf
Change-Id: I0cba5ab639f1e66b7c493a9f63735a0f5edbcfbf

Original message description:
========================================================================
If a webp file is truncated such that no rows can be decoded,
WebPIDecGetRGB does not initialize its "last_y" parameter. We use
rowsDecoded (passed as last_y) to determine which remaining rows to
fill.

Check the return value of WebPIDecGetRGB. If it fails (returns null),
or rowsDecoded is <= 0 (matching Chromium's check), return
kInvalidInput, since there is nothing to draw.

Note that this is a change in behavior for Android. Previously we
would decode an empty webp to just a transparent/black rectangle,
whereas now we simply fail. I think this is a change for the better.

Add a test which truncates a file to have 0 rows available and attempts
to decode it. msan verifies that we no longer depend on the
uninitialized value.

Stop attempting to test decoding subsets from an incomplete webp (in
CodecTest.cpp). Unless we have decoded the portion covered by the
subset, this will fail.

Remove test images inc0.webp (from both dm/ and colorspace/) and
inc1.webp. These just decode to transparent rectangles. Replace them
with inc2.webp and inc3.webp, which decode part of the image and then
have to fill with transparent.

Change-Id: I64d40be91c574b45963f9a43d8dd8f4929dd2939
Reviewed-on: https://skia-review.googlesource.com/50303
Commit-Queue: Leon Scroggins <scroggo@google.com>
Reviewed-by: James Zern <jzern@google.com>
========================================================================

For simplicity, this does not update VERSION or tasks.json, as does the
original CL. It also does not include the test, which relied on more
recent changes.

Exempt-From-Owner-Approval: I should be an OWNER.
(cherry picked from commit 99740b3bb9aae40c810005e1464d0428fa16bbf9)

Change-Id: I7c07c99273e4cd1a4ae98b794d49a125cff7507f
1 file changed