forked from qt-creator/qt-creator
deref instead of deleting
this would give a leak instead of a crash - if it was really relevant at all.
This commit is contained in:
@@ -65,7 +65,7 @@ static int evaluate(const QString &fileName, const QString &in_pwd, const QStrin
|
||||
if (!(pro = visitor.parsedProFile(fileName)))
|
||||
return 2;
|
||||
if (!visitor.accept(pro)) {
|
||||
delete pro;
|
||||
pro->deref();
|
||||
return 2;
|
||||
}
|
||||
|
||||
@@ -108,7 +108,7 @@ static int evaluate(const QString &fileName, const QString &in_pwd, const QStrin
|
||||
}
|
||||
}
|
||||
|
||||
delete pro;
|
||||
pro->deref();
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user