Fixes for iOS6