Skip to content

Commit

Permalink
Don't substitute command line arg with default
Browse files Browse the repository at this point in the history
For issue #307, as user may have explicitly removed the default.
  • Loading branch information
MattClarkson committed Mar 19, 2013
1 parent 4ca423a commit 85e98f2
Showing 1 changed file with 2 additions and 7 deletions.
Expand Up @@ -31,6 +31,7 @@
#include "ctkCmdLineModuleRunException.h"

#include "ctkUtils.h"
#include <iostream>
#include <QProcess>
#include <QUrl>

Expand Down Expand Up @@ -95,12 +96,6 @@ struct ctkCmdLineModuleBackendLocalProcessPrivate
{

QString trimmedArg = arg.trimmed();
QString trimmedDefault = parameter.defaultValue().trimmed();

if (trimmedArg.length() == 0)
{
trimmedArg = trimmedDefault;
}

if (parameter.tag() == "string")
{
Expand All @@ -115,7 +110,7 @@ struct ctkCmdLineModuleBackendLocalProcessPrivate
}
else
{
if (trimmedArg.length() != 0) // If not string, no arg, and no default, we don't output. We need this policy for integers, doubles, etc.
if (trimmedArg.length() != 0) // If not string, no arg, we don't output. We need this policy for integers, doubles, etc.
{
cmdLineArgs << argFlag << arg;
}
Expand Down

0 comments on commit 85e98f2

Please sign in to comment.