Have SkMipmap::Build return nullptr on mipmap allocation failure

This method is already allowed to return nullptr (and does so if the factory function version's allocation fails) so let it do so if the mipmaps can't be allocated.

Bug: chromium:1488128
Change-Id: If523e34ac3942f4c305bea34b33ee983fb61b570
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/762401
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
5 files changed