Skip to content

Commit

Permalink
Merge pull request #7227 from Mic92/git
Browse files Browse the repository at this point in the history
source/git: use finally block to delete ssh private key
  • Loading branch information
p12tic committed Dec 3, 2023
2 parents f227b3f + b305fa8 commit b623c79
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions master/buildbot/steps/source/git.py
Original file line number Diff line number Diff line change
Expand Up @@ -143,11 +143,9 @@ def run_vc(self, branch, revision, patch):
yield self.patch(patch)
yield self.parseGotRevision()
res = yield self.parseCommitDescription()
yield self._removeSshPrivateKeyIfNeeded()
return res
except Exception:
finally:
yield self._removeSshPrivateKeyIfNeeded()
raise

@defer.inlineCallbacks
def mode_full(self):
Expand Down

0 comments on commit b623c79

Please sign in to comment.