Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Backport (2-0-x) - Fix nil tray title crash #12356

Merged
merged 2 commits into from Mar 23, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
7 changes: 6 additions & 1 deletion atom/browser/ui/tray_icon_cocoa.mm
Expand Up @@ -230,8 +230,13 @@ - (void)updateAttributedTitle {
return;
}

// check title_ being nil
NSString *title = @"";
if (title_)
title = title_;

attributedTitle_.reset([[NSMutableAttributedString alloc]
initWithString:title_
initWithString:title
attributes:attributes]);

//NSFontAttributeName:[NSFont menuBarFontOfSize:0],
Expand Down