Fix some warnings

Unused functions & variables, initialization order, signedness, non-
virtual destructor.

Change-Id: I405d768fe0e02a36a16c2cead9e1bc2f6a23fb75
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
This commit is contained in:
Christian Kandeler
2021-09-01 17:04:16 +02:00
parent 391588d08e
commit 3be9f52980
9 changed files with 11 additions and 39 deletions

View File

@@ -434,32 +434,6 @@ void VcsOutputWindow::appendWarning(const QString &text)
append(text, Warning, false);
}
// Helper to format arguments for log windows hiding common password options.
static inline QString formatArguments(const QStringList &args)
{
const char passwordOptionC[] = "--password";
QString rc;
QTextStream str(&rc);
const int size = args.size();
// Skip authentication options
for (int i = 0; i < size; i++) {
const QString arg = filterPasswordFromUrls(args.at(i));
if (i)
str << ' ';
if (arg.startsWith(QString::fromLatin1(passwordOptionC) + '=')) {
str << ProcessArgs::quoteArg("--password=********");
continue;
}
str << ProcessArgs::quoteArg(arg);
if (arg == passwordOptionC) {
str << ' ' << ProcessArgs::quoteArg("********");
i++;
}
}
return rc;
}
QString VcsOutputWindow::msgExecutionLogEntry(const FilePath &workingDir, const CommandLine &command)
{
if (workingDir.isEmpty())