diff --git a/MachMgrMachGroups.cpp b/MachMgrMachGroups.cpp index 006a23b..4edbd6c 100644 --- a/MachMgrMachGroups.cpp +++ b/MachMgrMachGroups.cpp @@ -78,7 +78,7 @@ MachMgr::GetMachGroupNewName( string& sName) const if ( sName.empty()) sName = "Mach" ; // verifico che il nome sia unico - int nCount = 1 ; + int nCount = 0 ; string sOrigName = sName ; while ( GetMachGroupId( sName) != GDB_ID_NULL) { ++ nCount ; diff --git a/MachMgrOperations.cpp b/MachMgrOperations.cpp index 7f65774..c59552b 100644 --- a/MachMgrOperations.cpp +++ b/MachMgrOperations.cpp @@ -142,7 +142,7 @@ MachMgr::GetOperationNewName( string& sName) const if ( sName.empty()) sName = "Oper" ; // verifico che il nome sia unico - int nCount = 1 ; + int nCount = 0 ; string sOrigName = sName ; while ( GetOperationId( sName) != GDB_ID_NULL) { ++ nCount ; diff --git a/ToolsMgr.cpp b/ToolsMgr.cpp index 58b4662..df3934a 100644 --- a/ToolsMgr.cpp +++ b/ToolsMgr.cpp @@ -290,7 +290,7 @@ ToolsMgr::GetToolNewName( string& sName) const if ( sName.empty()) sName = "Tool" ; // verifico che il nome sia unico - int nCount = 1 ; + int nCount = 0 ; string sOrigName = sName ; while ( GetTool( sName) != nullptr) { ++ nCount ;