Clear the install marker on elevation failures too for PR #7490

The code 2 exit keeps the marker for the elevated run that follows, but every
terminal failure of that run, a denied prompt or a failed apt-get included,
returned without clearing it. That pinned a working install into repair the
same way a failed update did. finish_elevation_failure is the one path all of
them take.
This commit is contained in:
Daniel Han 2026-07-27 13:22:30 +00:00
commit b40d422654

View file

@ -914,6 +914,9 @@ fn finish_elevation_failure(
exit_status: Option<String>,
message: String,
) {
// Terminal, like a cancelled prompt: the run the code 2 exit left the
// marker for is not happening.
clear_install_marker_best_effort();
if let Some(attempt) = attempt {
diagnostics::finish_attempt(
diagnostics,