no message
This commit is contained in:
@@ -35,12 +35,14 @@ enum TestType{
|
||||
#pragma once
|
||||
class Task {
|
||||
protected:
|
||||
long id;
|
||||
long id;
|
||||
|
||||
int maxtime;
|
||||
int kernels; //получение зависит от типа задачи.
|
||||
String workspace;
|
||||
TaskState state;
|
||||
public:
|
||||
public:
|
||||
long start_time;
|
||||
String printState(){
|
||||
switch(state){
|
||||
case Inactive:
|
||||
@@ -146,7 +148,13 @@ public:
|
||||
//todo определить по интервалу времени на всякий случай.
|
||||
}else if (Utils::Exists(workspace+"/INTERRUPT")){
|
||||
state=AbortedByUser;
|
||||
}
|
||||
} else {
|
||||
long now = Utils::getAbsoluteTime();
|
||||
long delta = now-start_time;
|
||||
if (maxtime<delta){
|
||||
state=AbortedByTimeout;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (state!=Running){
|
||||
//-
|
||||
|
||||
Reference in New Issue
Block a user