iOS7 unsigned long type conversion fix