Bug fixes for Android