forked from qt-creator/qt-creator
Project: Make sure id() will never change
Warn and ignore attempts to change the id() of a project. Change-Id: I26c7c585e87d8be7b9fb8da3b3685b252e05f070 Reviewed-by: Eike Ziller <eike.ziller@qt.io>
This commit is contained in:
@@ -505,6 +505,7 @@ void Project::setDisplayName(const QString &name)
|
|||||||
|
|
||||||
void Project::setId(Core::Id id)
|
void Project::setId(Core::Id id)
|
||||||
{
|
{
|
||||||
|
QTC_ASSERT(!d->m_id.isValid(), return); // Id may not change ever!
|
||||||
d->m_id = id;
|
d->m_id = id;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user