fix device_is_simulator in device.cpp, caused app crash