summaryrefslogtreecommitdiffstats
path: root/src/libs/installer/environmentvariablesoperation.cpp
diff options
context:
space:
mode:
authorNiels Weber <niels.weber@digia.com>2013-02-12 11:12:50 +0100
committerNiels Weber <niels.weber@digia.com>2013-02-12 16:47:39 +0100
commit7fb982e711f8b12afa585d19851b1bb0b7b081a4 (patch)
tree50ebb4dfdd0749137d5c9a4a6b6e8e5a7a2f5e8b /src/libs/installer/environmentvariablesoperation.cpp
parent5e9a054369b5460fce784b0763c3264c7eabe9ec (diff)
Unify some error strings.
Change-Id: I3ce7d3f84c9654e5c457b9e5f6131ac931e8ba2f Reviewed-by: Karsten Heimrich <karsten.heimrich@digia.com>
Diffstat (limited to 'src/libs/installer/environmentvariablesoperation.cpp')
-rw-r--r--src/libs/installer/environmentvariablesoperation.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/libs/installer/environmentvariablesoperation.cpp b/src/libs/installer/environmentvariablesoperation.cpp
index 0e838798d..de2eae899 100644
--- a/src/libs/installer/environmentvariablesoperation.cpp
+++ b/src/libs/installer/environmentvariablesoperation.cpp
@@ -136,10 +136,11 @@ UpdateOperation::Error undoSetting(const QString &regPath,
bool EnvironmentVariableOperation::performOperation()
{
- if (arguments().count() < 2 || arguments().count() > 4) {
+ QStringList args = arguments();
+ if (args.count() != 2 && args.count() != 3) {
setError(InvalidArguments);
- setErrorString(tr("Invalid arguments in %0: %1 arguments given, 2-3 expected.")
- .arg(name()).arg(arguments().count()));
+ setErrorString(tr("Invalid arguments in %0: %1 arguments given, %2 expected%3.")
+ .arg(name()).arg(arguments().count()).arg(tr("2 or 3"), QLatin1String("")));
return false;
}