# HG changeset patch # User thomas_-_s # Date 1285569083 0 # Node ID edde9cbb2ce4b22ed699f440110918a0faf0e5f7 # Parent 0b7602d246e48fdc0c2c033423ce3ec72494b56a Corrected filtering of faulty finder command line parameter. git-svn-id: svn://svn.code.sf.net/p/universalindent/code/trunk@1019 59b1889a-e5ac-428c-b0c7-476e01d41282 diff -r 0b7602d246e4 -r edde9cbb2ce4 src/main.cpp --- a/src/main.cpp Sun Sep 19 16:36:50 2010 +0000 +++ b/src/main.cpp Mon Sep 27 06:31:23 2010 +0000 @@ -130,7 +130,7 @@ for ( int i = 0; i < argc; i++ ) { QString argString(argv[i]); - if ( argString.startsWith("-psn_") ) { + if ( argString.startsWith("-psn_") == false ) { argList.push_back(argv[i]); } else { @@ -143,9 +143,9 @@ argc = argList.size(); #endif - // Wrap everything in a try block. Do this every time, - // because exceptions will be thrown for problems. - try { + // Wrap everything in a try block. Do this every time, + // because exceptions will be thrown for problems. + try { // Define the command line object. TCLAP::CmdLine cmd("If -p and -s are set, -p will be used.\nGiving no parameters starts full gui without server.", ' ', "UiGUI version " PROGRAM_VERSION_STRING " " PROGRAM_REVISION); cmd.setExceptionHandling(false); @@ -169,7 +169,7 @@ // Parse the args. cmd.parse( argc, argv ); - // Get the value parsed by each arg. + // Get the value parsed by each arg. file2OpenOnStart = QString::fromStdString( filenameArg.getValue() ); startAsPlugin = pluginSwitch.getValue(); startAsServer = serverSwitch.getValue();