Check for Potential Null Pointer
After calling the function AndroidBitmap_lockPixels(), neither the
return value nor the returned pointers were checked for the possible
failure. So the pointers "source" & "destination" could have invalid
value.
Along with changes above, we also have some compile warnings and code
format cleaned.
Test: mmm packages/apps/Gallery2, presubmit check.
Change-Id: I28a5d678311cb963bacd6f7b96ca2e12d498d965
Signed-off-by: Jing Mike <jingyangliu@eswincomputing.com>
3 files changed