diff --git a/Common/CommandLine.cpp b/Common/CommandLine.cpp index eba68b50b8172f68d642f986a2cbca342ec17a7c..0cb5506c663eac9bafdc8daebaba145d58c0fe76 100644 --- a/Common/CommandLine.cpp +++ b/Common/CommandLine.cpp @@ -819,13 +819,11 @@ void GetOptions(int argc, char *argv[]) } else if(!strcmp(argv[i] + 1, "rec")) { i++; - if(argv[i]) { - CTX::instance()->mesh.doRecombinationTest = 1; - CTX::instance()->mesh.recTestName = argv[i]; - i++; - } - else - Msg::Fatal("Missing file name for recomb"); + if (argc - i < 3) Msg::Fatal("pas assez argument"); + CTX::instance()->mesh.doRecombinationTest = 1; + CTX::instance()->mesh.recTestName = argv[i]; i++; + CTX::instance()->mesh.nProc = atoi(argv[i]); i++; + CTX::instance()->mesh.nbProc = atoi(argv[i]); i++; } else if(!strcmp(argv[i] + 1, "beg")) { i++; diff --git a/Common/Context.h b/Common/Context.h index 14337412ec1ff8543c7da209d5335c898ed2d21d..f99cce39f93206f8984f6b5eeca66c1d931d0bdc 100644 --- a/Common/Context.h +++ b/Common/Context.h @@ -36,6 +36,7 @@ struct contextMeshOptions { //-- for recombination test (amaury) -- int doRecombinationTest, recombinationTestStart; int recombinationTestNoGreedyStrat, recombinationTestNewStrat; + int nProc, nbProc; std::string recTestName; //------------------------------------- int remeshParam, remeshAlgo;