diff options
Diffstat (limited to 'infra/dgit-repos-policy-debian')
-rwxr-xr-x | infra/dgit-repos-policy-debian | 31 |
1 files changed, 9 insertions, 22 deletions
diff --git a/infra/dgit-repos-policy-debian b/infra/dgit-repos-policy-debian index 467a417..fc7f1b1 100755 --- a/infra/dgit-repos-policy-debian +++ b/infra/dgit-repos-policy-debian @@ -471,46 +471,33 @@ END my $ti = $taintinfoq->fetchrow_hashref(); die "($taintid)" unless $ti; - my $timeshow = defined $ti->{time} - ? " at time ".strftime("%Y-%m-%d %H:%M:%S Z", gmtime $ti->{time}) - : ""; - my $pkgshow = length $ti->{package} - ? "package $ti->{package}" - : "any package"; - - $stderr .= <<END; - -History contains tainted $objtype $objid -Taint recorded$timeshow for $pkgshow -Reason: $ti->{comment} -END - printdebug "SQL overrides: @overridesv $taintid /\n$overridesstmt\n"; $overridesq ||= $poldbh->prepare($overridesstmt); $overridesq->execute(@overridesv, $taintid); my ($ovwhy) = $overridesq->fetchrow_array(); + my $ovstatus; if (!defined $ovwhy) { $overridesanyq ||= $poldbh->prepare(<<END); SELECT 1 FROM taintoverrides WHERE taint_id = ? LIMIT 1 END $overridesanyq->execute($taintid); my ($ovany) = $overridesanyq->fetchrow_array(); - $stderr .= $ovany ? <<END : <<END; -Could be forced using --deliberately. Consult documentation. -END -Uncorrectable error. If confused, consult administrator. -END + $ovwhy = $ovany ? '' : undef; $mustreject = 1; } else { - $stderr .= <<END; -Forcing due to $ovwhy -END $untaintq ||= $poldbh->prepare(<<END); DELETE FROM taints WHERE taint_id = ? END $untaintq->execute($taintid); } + + $stderr .= tainted_objects_message { + %$ti, + gitobjid => $objid, + gitobjtype => $objtype, + }, $ovstatus; + } close CHKOUT; |