Index: chrome/browser/ui/cocoa/browser/avatar_icon_controller.mm |
diff --git a/chrome/browser/ui/cocoa/browser/avatar_icon_controller.mm b/chrome/browser/ui/cocoa/browser/avatar_icon_controller.mm |
index ca1f78f4d2b5595ee523d495c02131b47574a427..7eca9578418565ae670de3d93acc16a1dc46fb06 100644 |
--- a/chrome/browser/ui/cocoa/browser/avatar_icon_controller.mm |
+++ b/chrome/browser/ui/cocoa/browser/avatar_icon_controller.mm |
@@ -181,6 +181,12 @@ const CGFloat kAvatarLabelRightSpacing = 2; |
// Updates the avatar information from the profile cache. |
- (void)updateAvatarButtonAndLayoutParent:(BOOL)layoutParent { |
+ // No updates are needed for an incognito or guest window, as the avatar |
+ // is always fixed. |
+ Profile* profile = browser_->profile(); |
+ if (profile->IsOffTheRecord() || profile->IsGuestSession()) |
+ return; |
+ |
ProfileInfoCache& cache = |
g_browser_process->profile_manager()->GetProfileInfoCache(); |
size_t index = |