segfault with gcc

This commit is contained in:
Hieu Hoang 2016-08-11 16:28:00 +02:00
parent 984894ffad
commit 5f3239963e
2 changed files with 5 additions and 1 deletions

View File

@ -30,6 +30,10 @@ int main(int argc, char** argv)
Moses2::System system(params);
timer.check("Loaded");
if (params.GetParam("show-weights")) {
return 0;
}
//cerr << "system.numThreads=" << system.options.server.numThreads << endl;
Moses2::ThreadPool pool(system.options.server.numThreads, system.cpuAffinityOffset, system.cpuAffinityOffsetIncr);

View File

@ -44,7 +44,7 @@ System::System(const Parameter &paramsArg) :
if (params.GetParam("show-weights")) {
cerr << "Showing weights then exit" << endl;
featureFunctions.ShowWeights(weights);
exit(1);
return;
}
cerr << "START featureFunctions.Load()" << endl;