Arrays.copyOf is only available from API 9 on Android