diff options
| author | Cassio de Campos <cassiopc@gmail.com> | 2017-11-10 23:28:48 +0000 |
|---|---|---|
| committer | Cassio de Campos <cassiopc@gmail.com> | 2017-11-10 23:28:48 +0000 |
| commit | 3cffb81354aac30059bef53406b6dcb96e262782 (patch) | |
| tree | debd1580dcc6d77a55948aba6eaedfb6f1adddf3 /src | |
| parent | 9a11d23c8855dc62a785d30a5f5c36d26115dfb2 (diff) | |
| download | boca-3cffb81354aac30059bef53406b6dcb96e262782.tar.gz boca-3cffb81354aac30059bef53406b6dcb96e262782.zip | |
bf
Diffstat (limited to 'src')
| -rw-r--r-- | src/admin/run.php | 2 | ||||
| -rw-r--r-- | src/frun.php | 11 | ||||
| -rw-r--r-- | src/fscore.php | 2 | ||||
| -rw-r--r-- | src/judge/runchief.php | 2 |
4 files changed, 8 insertions, 9 deletions
diff --git a/src/admin/run.php b/src/admin/run.php index 4293881..cc0bb46 100644 --- a/src/admin/run.php +++ b/src/admin/run.php @@ -89,7 +89,7 @@ if(isset($_POST)) { $us = DBAllUserNames($_SESSION["usertable"]["contestnumber"]); for ($i=0; $i<count($run); $i++) { - if($run[$i]["answer1"] != 0 && $run[$i]["answer2"] != 0 && $run[$i]["status"] != "judged") { + if($run[$i]["answer1"] != 0 && $run[$i]["answer2"] != 0 && ($run[$i]["status"] != "judged" && $run[$i]["status"] != 'deleted')) { if($runphp == "runchief.php") echo " <tr bgcolor=\"ff0000\">\n"; else echo "<tr>\n"; diff --git a/src/frun.php b/src/frun.php index d920e74..473c4a5 100644 --- a/src/frun.php +++ b/src/frun.php @@ -15,7 +15,6 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see <http://www.gnu.org/licenses/>. //////////////////////////////////////////////////////////////////////////////// -// Last modified 29/aug/2017 by cassio@ime.usp.br function DBDropRunTable() { $c = DBConnect(); @@ -499,16 +498,16 @@ function DBUpdateRunAutojudging($contest, $site, $number, $ip, $answer, $stdout, $a["runproblem"] == 11 || $a["runproblem"] == 12 || $a["runproblem"] == 13) - && $retval != 4 && $retval != 6)) { // but WA and TLE are automatic for all problems - - if($b["siteautojudge"]!="t") { + && $retval != 4 && $retval != 6)) { // but WA:6 and TLE:4 are automatic for all problems + if($retval != 1 && $retval != 6 && $retval != 4) { + //if($b["siteautojudge"]!="t") { // && (($retval != 1 && $retval != 6) || $a["runproblem"] == 1 || $a["runproblem"] == 2) ) { //cassiopc incluir automatic judging of some codes 1:YES WA:6 DBExec($c, "commit work", "DBUpdateRunAutojudging(commit)"); LOGLevel("Autojudging answered a run (run=$number, site=$site, contest=$contest, answer='$answer', retval=$retval)", 3); return true; - } + //} + } } - //echo "DEBUG: $contest, $site, " .$a["usernumber"].", $site, $number, $retval\n"; if(DBUpdateRunO($contest, $site, $a["usernumber"], $site, $number, $retval, $c)==false) { DBExec($c, "rollback work", "DBUpdateRunAutoJudging(rollback)"); diff --git a/src/fscore.php b/src/fscore.php index ec03091..6faeb63 100644 --- a/src/fscore.php +++ b/src/fscore.php @@ -374,7 +374,7 @@ function DBScoreSite($contest, $site, $verifylastmile, $hor=-1, $data=null) { if ($i>=$n) break; if($a[$i]["anstime"] <= $ta && $a[$i]["user"]==$user && $a[$i]["problem"]==$problem && $a[$i]["yes"]=='t') { $timet = (int) (($a[$i]["time"])/60); - if(!isset($resp[$user . '-' . $site]["first"]) || $timet < $resp[$user . '-' . $site]["first"]) + if(!isset($resp[$user . '-' . $site]["first"]) || $timet > $resp[$user . '-' . $site]["first"]) // > means last run, < would be first run $resp[$user . '-' . $site]["first"] = $timet; $time += $timet; $resp[$user . '-' . $site]["problem"][$problem]["time"] = $timet; diff --git a/src/judge/runchief.php b/src/judge/runchief.php index a4cd443..7238bed 100644 --- a/src/judge/runchief.php +++ b/src/judge/runchief.php @@ -89,7 +89,7 @@ if(isset($_POST)) { for ($i=0; $i<count($run); $i++) { - if($run[$i]["answer1"] != 0 && $run[$i]["answer2"] != 0 && $run[$i]["status"] != "judged") { + if($run[$i]["answer1"] != 0 && $run[$i]["answer2"] != 0 && ($run[$i]["status"] != "judged" && $run[$i]["status"] != 'deleted')) { if($runphp == "runchief.php") echo " <tr bgcolor=\"ff0000\">\n"; else echo "<tr>\n"; |