Android: on rare occasion, prevent Android_JNI_GetNativeWindow() from crashing If Java getNativeSurface() returns null, then ANativeWindow_fromSurface() would crash().