You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Uses a cleanupLocker boolean that gets set just before calling RegisterInstallBegining to control whether the locker gets cleaned up by the finally block. This prevents early returning code that is meant for any arbitrary requests made during the installation/upgrade process to remove the lock prematurely.
It makes the finally block execute cleanup only if the code exits after the RegisterInstallBegining call.
Eliminates both the slight chance that if an exception in RegisterInstallBegining() happens the locker file will not be cleaned up and the no additional code should be written in the future between the lock and the try code blocks cases.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #6859
Summary
Uses a
cleanupLockerboolean that gets set just before callingRegisterInstallBeginingto control whether the locker gets cleaned up by the finally block. This prevents early returning code that is meant for any arbitrary requests made during the installation/upgrade process to remove the lock prematurely.