Fix memory leak in system

This commit is contained in:
robotbrain
2014-02-24 17:49:18 -05:00
parent 55e21737dd
commit b1cddb4600
3 changed files with 7 additions and 7 deletions

View File

@ -88,10 +88,10 @@ void ScreenshotList::deleteSelected(ScreenshotDialog *dialog)
return;
}
beginResetModel();
QList<ScreenShot *>::const_iterator it;
QList<std::shared_ptr<ScreenShot>>::const_iterator it;
for (it = screens.cbegin(); it != screens.cend(); it++)
{
ScreenShot *shot = *it;
std::shared_ptr<ScreenShot> = *it;
if (!QFile(shot->file).remove())
{
CustomMessageBox::selectable(dialog, tr("Error!"),