From fc88a4bdd2c6e82bc167a7f64b67cd6b4d49777c Mon Sep 17 00:00:00 2001 From: Axel Modave <axel.modave@gmail.com> Date: Tue, 29 Jul 2014 14:45:31 +0000 Subject: [PATCH] fix commandLine for partition with weights\ntri in the documentation, triangle in the code\nnow, both are allowed (only one should be allowed?) --- Common/CommandLine.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/Common/CommandLine.cpp b/Common/CommandLine.cpp index 21cd26ddb5..405cb591de 100644 --- a/Common/CommandLine.cpp +++ b/Common/CommandLine.cpp @@ -369,7 +369,7 @@ void GetOptions(int argc, char *argv[]) opt_mesh_partition_metis_algorithm(0, GMSH_SET, 3); // partGraphKWay w/ weights while (check) { if (argv[i]) { - if (!strcmp(argv[i],"triangle")) { + if (!strcmp(argv[i],"tri") || !strcmp(argv[i],"triangle")) { i++; opt_mesh_partition_tri_weight(0,GMSH_SET,atoi(argv[i])); } @@ -393,7 +393,10 @@ void GetOptions(int argc, char *argv[]) i++; opt_mesh_partition_hex_weight(0,GMSH_SET,atoi(argv[i])); } - else check = false; + else { + Msg::Error("Bad argument for 'partWeight' (%s)", argv[i]); + check = false; + } i++; } else check = false; -- GitLab