the score gained by the hacked submission is not 100.\n"; $esc_details = DB::escape(uojTextEncode($details)); DB::update("update hacks set success = 0, details = '$esc_details' where id = {$hack['id']}"); return false; } return true; } return false; } if (isset($_POST['fetch_new']) && !$_POST['fetch_new']) { die("Nothing to judge"); } if (!findSubmissionToJudge()) { die("Nothing to judge"); } $submission['id'] = (int)$submission['id']; $submission['problem_id'] = (int)$submission['problem_id']; $submission['problem_mtime'] = filemtime("/var/uoj_data/{$submission['problem_id']}.zip"); $submission['content'] = json_decode($submission['content']); if ($hack) { $submission['is_hack'] = ""; $submission['hack']['id'] = (int)$hack['id']; $submission['hack']['input'] = $hack['input']; $submission['hack']['input_type'] = $hack['input_type']; } echo json_encode($submission); ?>