Fixes for various Android issues