diff --git a/src/slic3r/GUI/CalibrationWizardPresetPage.cpp b/src/slic3r/GUI/CalibrationWizardPresetPage.cpp index a6fa8331f..b8bf3787a 100644 --- a/src/slic3r/GUI/CalibrationWizardPresetPage.cpp +++ b/src/slic3r/GUI/CalibrationWizardPresetPage.cpp @@ -1588,6 +1588,8 @@ void CalibrationPresetPage::update_combobox_filaments(MachineObject* obj) } Preset* printer_preset = get_printer_preset(obj, nozzle_value); + if (!printer_preset) + return; auto opt_extruder_type = printer_preset->config.option("extruder_type"); if (opt_extruder_type) { diff --git a/src/slic3r/GUI/Plater.cpp b/src/slic3r/GUI/Plater.cpp index 962ea9ba9..d8ab62966 100644 --- a/src/slic3r/GUI/Plater.cpp +++ b/src/slic3r/GUI/Plater.cpp @@ -1112,6 +1112,9 @@ bool Sidebar::priv::sync_extruder_list() PresetBundle *preset_bundle = wxGetApp().preset_bundle; std::string target_model_id = preset_bundle->printers.get_selected_preset().get_printer_type(preset_bundle); Preset* machine_preset = get_printer_preset(obj); + if (!machine_preset) + return false; + if (machine_print_name != target_model_id) { MessageDialog dlg(this->plater, _L("The currently selected machine preset is inconsistent with the connected printer type.\n" "Are you sure to continue syncing?"), _L("Sync extruder infomation"), wxICON_WARNING | wxYES | wxNO);