mirror of
https://github.com/leozide/leocad
synced 2024-12-27 21:58:37 +01:00
Fixed warnings.
This commit is contained in:
parent
e28b7d29e5
commit
6a48e8ddc8
1 changed files with 4 additions and 4 deletions
|
@ -61,9 +61,9 @@ void PieceInfo::SetModel(lcModel* Model, bool UpdateMesh, Project* CurrentProjec
|
|||
mModel = Model;
|
||||
}
|
||||
|
||||
strncpy(mFileName, Model->GetProperties().mFileName.toLatin1().data(), sizeof(mFileName));
|
||||
strncpy(mFileName, Model->GetProperties().mFileName.toLatin1().data(), sizeof(mFileName) - 1);
|
||||
mFileName[sizeof(mFileName)-1] = 0;
|
||||
strncpy(m_strDescription, Model->GetProperties().mFileName.toLatin1().data(), sizeof(m_strDescription));
|
||||
strncpy(m_strDescription, Model->GetProperties().mFileName.toLatin1().data(), sizeof(m_strDescription) - 1);
|
||||
m_strDescription[sizeof(m_strDescription)-1] = 0;
|
||||
|
||||
const QStringList& MeshLines = Model->GetFileLines();
|
||||
|
@ -100,9 +100,9 @@ void PieceInfo::CreateProject(Project* Project, const char* PieceName)
|
|||
mState = LC_PIECEINFO_LOADED;
|
||||
}
|
||||
|
||||
strncpy(mFileName, PieceName, sizeof(mFileName));
|
||||
strncpy(mFileName, PieceName, sizeof(mFileName) - 1);
|
||||
mFileName[sizeof(mFileName) - 1] = 0;
|
||||
strncpy(m_strDescription, Project->GetFileName().toLatin1().data(), sizeof(m_strDescription));
|
||||
strncpy(m_strDescription, Project->GetFileName().toLatin1().data(), sizeof(m_strDescription) - 1);
|
||||
m_strDescription[sizeof(m_strDescription) - 1] = 0;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue