$opens{$problem, $owner} = $time;
}
- my $jobs = $db->select('job_entry', '*', {contest => $ct->{id}}, 'id');
+ # result IS NULL if job was never run
+ # result = -2 if job is being rerun
+ my %where = (contest => $ct->{id}, result => {'>=', 0});
+ my $jobs = $db->select('job_entry', '*', \%where, 'id');
while (my $job = $jobs->hash) {
my $open = $opens{$job->{problem}, $job->{owner}} // $ct->{start};