mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-13 01:37:53 -06:00
Fix of [prusa3d/PrusaSlicer] Remove unnecessary null pointer checks (#5813)
Don't use if (ptr) delete ptr; call delete ptr; directly, it contains the test for null ptr.
This commit is contained in:
parent
d06aa60691
commit
9a2310ae98
3 changed files with 7 additions and 18 deletions
|
@ -595,17 +595,10 @@ struct Sidebar::priv
|
|||
|
||||
Sidebar::priv::~priv()
|
||||
{
|
||||
if (object_manipulation != nullptr)
|
||||
delete object_manipulation;
|
||||
|
||||
if (object_settings != nullptr)
|
||||
delete object_settings;
|
||||
|
||||
if (frequently_changed_parameters != nullptr)
|
||||
delete frequently_changed_parameters;
|
||||
|
||||
if (object_layers != nullptr)
|
||||
delete object_layers;
|
||||
delete object_manipulation;
|
||||
delete object_settings;
|
||||
delete frequently_changed_parameters;
|
||||
delete object_layers;
|
||||
}
|
||||
|
||||
void Sidebar::priv::show_preset_comboboxes()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue