Fix double-free when removing lock popup#6
Open
p1gp1g wants to merge 4 commits intotgc-dk:button-unlockfrom
Open
Fix double-free when removing lock popup#6p1gp1g wants to merge 4 commits intotgc-dk:button-unlockfrom
p1gp1g wants to merge 4 commits intotgc-dk:button-unlockfrom
Conversation
When the device is woken through pressing the button everything is the same. But when woken through other means like single-tap or raise-to-wake, then the screen is locked (and showing a lock screen on touch input) until the button is pressed. Only exception is when the alarm wakes the screen, then touch input is still valid for the user to be able to press the red "stop alarm" button. Co-authored-by: NeroBurner <pyro4hell@gmail.com>
d00a8c1 to
f0d7298
Compare
NeroBurner
reviewed
Jul 20, 2025
| // This is mainly to fix an issue with receiving two notifications at the same time | ||
| // and shouldn't happen otherwise. | ||
| if (app != currentApp) { | ||
| popupMessage.SetHidden(true); |
There was a problem hiding this comment.
please add an additional comment describing why we do SetHidden here, otherwise the comment above doesn't fully represent the code below anymore. Other than that big THANKS for the fix!
It fixes a potential double-free when removing lock popup
f0d7298 to
ea52fb7
Compare
|
merged into button-unlock Thanks |
131f294 to
10344e5
Compare
f2be229 to
f1e5dbc
Compare
f1e5dbc to
a507abc
Compare
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
When the popup is created on the notifications view, and the user return to the watch face; The popup is deleted and freed, but
popupwasn't not set tonullptr, andisHiddento false so we ended up deleting again the popup. The best way to handle that is to always remove the popup when changing app. If the user click again, a new popup will show