QDoc: Do not warn about a file overwritting while writing to /dev/null
Change-Id: I7d23edf5a73d521bad361f1007be0750acd4c1e9 Reviewed-by: Topi Reiniö <topi.reinio@digia.com> Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
This commit is contained in:
parent
7aa1a7f1c1
commit
742e0fb560
@ -270,7 +270,7 @@ void Generator::beginSubPage(const InnerNode* node, const QString& fileName)
|
||||
path += fileName;
|
||||
|
||||
QFile* outFile = new QFile(redirectDocumentationToDevNull_ ? QStringLiteral("/dev/null") : path);
|
||||
if (outFile->exists())
|
||||
if (!redirectDocumentationToDevNull_ && outFile->exists())
|
||||
node->location().error(tr("HTML file already exists; overwriting %1").arg(outFile->fileName()));
|
||||
if (!outFile->open(QFile::WriteOnly))
|
||||
node->location().fatal(tr("Cannot open output file '%1'").arg(outFile->fileName()));
|
||||
|
Loading…
x
Reference in New Issue
Block a user