Replaced strtod with c_strtod where appropriate