I\'ve been reading the other posts on tracking down the reasons for getting a SIGSEGV
in an Android app. I plan to scour my app for possible NullPointers relate
I've encountered this error when I tried to access the 'canvas' outside of onDraw()
private Canvas canvas;
@Override
protected void onDraw(Canvas canvas) {
this.canvas = canvas;
....... }
private class ScaleListener extends ScaleGestureDetector.SimpleOnScaleGestureListener {
@Override
public boolean onScale(ScaleGestureDetector detector) {
canvas.save(); // here
A very bad practice :/