Skip to content

Commit

Permalink
Merge pull request #92 from zhblue/master
Browse files Browse the repository at this point in the history
quick sync
  • Loading branch information
zhblue authored Nov 21, 2016
2 parents 7886b55 + 38ccdaa commit f75aab8
Showing 1 changed file with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions trunk/core/judge_client/judge_client.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1990,8 +1990,7 @@ void clean_workdir(char * work_dir) {
if (DEBUG) {
execute_cmd("/bin/mv %s/* %slog/", work_dir, work_dir);
} else {
execute_cmd("/bin/rm -rf %s/*", work_dir);

execute_cmd("/bin/rm -f %s/*", work_dir);
}

}
Expand Down Expand Up @@ -2230,10 +2229,8 @@ int main(int argc, char** argv) {
update_problem(p_id);
if (!http_judge)
mysql_close(conn);
if (!DEBUG)
clean_workdir(work_dir);
else
write_log("compile error");
clean_workdir(work_dir);
write_log("compile error");
exit(0);
} else {
update_solution(solution_id, OJ_RI, 0, 0, 0, 0, 0.0);
Expand Down Expand Up @@ -2319,7 +2316,7 @@ int main(int argc, char** argv) {
addcustomout(solution_id);
}
update_solution(solution_id, OJ_TR, usedtime, topmemory >> 10, 0, 0, 0);

clean_workdir(work_dir);
exit(0);
}

Expand Down

0 comments on commit f75aab8

Please sign in to comment.