diff --git a/src/plugins/qt4projectmanager/qt-maemo/qt4maemotarget.cpp b/src/plugins/qt4projectmanager/qt-maemo/qt4maemotarget.cpp index 6f0c02d26de..55d000d127e 100644 --- a/src/plugins/qt4projectmanager/qt-maemo/qt4maemotarget.cpp +++ b/src/plugins/qt4projectmanager/qt-maemo/qt4maemotarget.cpp @@ -246,11 +246,7 @@ QSharedPointer AbstractQt4MaemoTarget::openFile(const QString &filePath, { const QString nativePath = QDir::toNativeSeparators(filePath); QSharedPointer file(new QFile(filePath)); - if (mode == QIODevice::ReadOnly && !file->exists()) { - if (error) - *error = tr("File '%1' does not exist").arg(nativePath); - file.clear(); - } else if (!file->open(mode)) { + if (!file->open(mode)) { if (error) { *error = tr("Cannot open file '%1': %2") .arg(nativePath, file->errorString());