diff --git a/src/main.cpp b/src/main.cpp index 7fb12fe..0f2c56b 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -143,10 +143,10 @@ int main(int argc, char* argv[]) { std::filesystem::create_directory(buildDir); } LOG("getting run time out") - int runtimeout = 0; - if(jsonValue["runtimeout"]!=Json::nullValue){ - runtimeout = jsonValue["runtimeout"].asInt(); - printValue(runtimeout) + int run_timeout = 0; + if(jsonValue["run_timeout"]!=Json::nullValue){ + run_timeout = jsonValue["run_timeout"].asInt(); + printValue(run_timeout) } LOG("compiling") string compileCommands; @@ -219,8 +219,8 @@ int main(int argc, char* argv[]) { } vector results(jsonTests.size()+1); for(auto &i:futures){ - if(runtimeout>0){ - if(i.wait_for(std::chrono::milliseconds(runtimeout))==std::future_status::ready){ + if(run_timeout>0){ + if(i.wait_for(std::chrono::milliseconds(run_timeout))==std::future_status::ready){ auto ret = i.get(); results[ret.id]=ret; } diff --git a/tests/xj.json b/tests/xj.json index bc74c42..eabf94d 100644 --- a/tests/xj.json +++ b/tests/xj.json @@ -15,5 +15,5 @@ "ans":"2.ans" } ], - "runtimeout":100 + "run_timeout":100 } \ No newline at end of file