fix iOS6 support.