Skip to content

Commit

Permalink
Fixed a bug in CLI that was not considering the PWD when dealing with
Browse files Browse the repository at this point in the history
input/output files (issue #690).
  • Loading branch information
rkhaotix committed May 24, 2015
1 parent be1353f commit 9c340fa
Showing 1 changed file with 0 additions and 10 deletions.
10 changes: 0 additions & 10 deletions main-cli/src/pgmodelercli.cpp
Expand Up @@ -297,11 +297,6 @@ accepted structure. All available options are described below.") << endl;

void PgModelerCLI::parseOptions(attribs_map &opts)
{
QString orig_work_dir=QDir::current().absolutePath();

//Changing the current working dir to the executable's directory in
QDir::setCurrent(this->applicationDirPath());

//Loading connections
if(opts.count(LIST_CONNS) || opts.count(EXPORT_TO_DBMS))
{
Expand Down Expand Up @@ -367,13 +362,8 @@ void PgModelerCLI::parseOptions(attribs_map &opts)
throw Exception(trUtf8("Invalid action specified to update mime option!"), ERR_CUSTOM,__PRETTY_FUNCTION__,__FILE__,__LINE__);

//Converting input and output files to absolute paths to avoid that they are read/written on the app's working dir
QDir::setCurrent(orig_work_dir);
opts[INPUT]=input_fi.absoluteFilePath();
opts[OUTPUT]=output_fi.absoluteFilePath();

//Changing the current working dir to the executable's directory in
QDir::setCurrent(this->applicationDirPath());

parsed_opts=opts;
}
}
Expand Down

0 comments on commit 9c340fa

Please sign in to comment.