#222 crash fix when thumbnails define with no values.

This commit is contained in:
supermerill 2020-09-06 23:45:27 +02:00
parent d3dd002931
commit e7ee5516a2

View File

@ -4488,6 +4488,9 @@ void PrintConfigDef::handle_legacy(t_config_option_key &opt_key, std::string &va
float v = boost::lexical_cast<float>(value);
if (v > 0)
value = boost::lexical_cast<std::string>(-v);
} else if (opt_key == "thumbnails") {
if (value.empty())
value = "0x0,0x0";
} else if (opt_key == "z_steps_per_mm") {
opt_key = "z_step";
float v = boost::lexical_cast<float>(value);