Skip to content

fix: crash when tray is destroyed - #14347

Merged
codebytere merged 1 commit into
masterfrom
tray_destroy_patch
Aug 28, 2018
Merged

codebytere merged 1 commit into
masterfrom
tray_destroy_patch

Conversation

@deepak1556

@deepak1556 deepak1556 commented Aug 28, 2018 •

Copy link
Copy Markdown
Member
Description of Change

The issue became visible after the specs that were added in #14322

    frame #1: 0x0000000100bf0364 Electron Framework`::-[StatusItemView shouldHighlight](self=0x000000013aee8e40, _cmd="shouldHighlight") at tray_icon_cocoa.mm:424
    frame #2: 0x0000000100bee3ac Electron Framework`::-[StatusItemView isHighlighted](self=0x000000013aee8e40, _cmd="isHighlighted") at tray_icon_cocoa.mm:151
    frame #3: 0x0000000100beed41 Electron Framework`::-[StatusItemView updateAttributedTitle](self=0x000000013aee8e40, _cmd="updateAttributedTitle") at tray_icon_cocoa.mm:262
    frame #4: 0x0000000100bf0267 Electron Framework`::-[StatusItemView setNeedsDisplay:](self=0x000000013aee8e40, _cmd="setNeedsDisplay:", display=YES) at tray_icon_cocoa.mm:413
    frame #5: 0x00007fff2b98c70c AppKit`-[NSView _viewDidChangeAppearance:] + 290
    frame #6: 0x00007fff2b98c3a2 AppKit`-[NSView _recursiveSendViewDidChangeAppearance:] + 57
    frame #7: 0x00007fff2b98c45e AppKit`-[NSView _recursiveSendViewDidChangeAppearance:] + 245
    frame #8: 0x00007fff2b954c5e AppKit`-[NSView _setSuperview:] + 1307
    frame #9: 0x00007fff2b95979d AppKit`-[NSView removeFromSuperview] + 252
    frame #10: 0x00007fff2ba6d32c AppKit`-[NSView removeFromSuperviewWithoutNeedingDisplay] + 38
    frame #11: 0x00007fff2c21c998 AppKit`-[NSView _finalize] + 1068
    frame #12: 0x00007fff2b96757a AppKit`-[NSView dealloc] + 164
    frame #13: 0x00007fff2bbe6249 AppKit`-[NSNextStepFrame dealloc] + 94
    frame #14: 0x00007fff2bbc2149 AppKit`-[NSWindow dealloc] + 1480
    frame #15: 0x00007fff2c0fa053 AppKit`-[NSStatusBarWindow dealloc] + 133
Checklist
  • PR description included and stakeholders cc'd
  • npm test passes
  • tests are changed or added
  • relevant documentation is changed or added
  • PR title follows semantic commit guidelines
Release Notes

Notes: fix crash when tray is destroyed

Release the view of status item before destroying it,
gives chance to perform cleanup on the view.
@deepak1556
deepak1556 requested review from a team, ckerr and miniak August 28, 2018 08:26

@ckerr ckerr left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ahh, I should've noticed this!

Thanks for the fix @deepak1556 👍

@codebytere
codebytere merged commit 07d017d into master Aug 28, 2018
@release-clerk

release-clerk Bot commented Aug 28, 2018

Copy link
Copy Markdown

Release Notes Persisted

fix crash when tray is destroyed

@trop

trop Bot commented Aug 28, 2018

Copy link
Copy Markdown
Contributor

An error occurred while attempting to backport this PR to "1-8-x",
you will need to perform this backport manually

@trop

trop Bot commented Aug 28, 2018

Copy link
Copy Markdown
Contributor

An error occurred while attempting to backport this PR to "2-0-x",
you will need to perform this backport manually

@trop

trop Bot commented Aug 28, 2018

Copy link
Copy Markdown
Contributor

We have automatically backported this PR to "3-0-x", please check out #14357

@trop trop Bot added merged/3-0-x and removed target/3-0-x labels Aug 28, 2018
@deepak1556
deepak1556 deleted the tray_destroy_patch branch August 28, 2018 20:16
@MarshallOfSound

Copy link
Copy Markdown
Member

/trop run backport-to 1-8-x,2-0-x

@trop

trop Bot commented Aug 28, 2018

Copy link
Copy Markdown
Contributor

The backport process for this PR has been manually initiated,
sending your 1's and 0's to "1-8-x" here we go! :D

@trop

trop Bot commented Aug 28, 2018

Copy link
Copy Markdown
Contributor

The backport process for this PR has been manually initiated,
sending your 1's and 0's to "2-0-x" here we go! :D

@trop

trop Bot commented Aug 28, 2018

Copy link
Copy Markdown
Contributor

We have automatically backported this PR to "1-8-x", please check out #14365

@trop

trop Bot commented Aug 28, 2018

Copy link
Copy Markdown
Contributor

We have automatically backported this PR to "2-0-x", please check out #14366

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants