Index: content/common/chrome_application_mac.mm |
diff --git a/content/common/chrome_application_mac.mm b/content/common/chrome_application_mac.mm |
index 81b341c62568f12ebd388f0324381d43e9f5af9f..5af70e9f48e45dbe7b511ab6dc0e0ff27b2fd6bf 100644 |
--- a/content/common/chrome_application_mac.mm |
+++ b/content/common/chrome_application_mac.mm |
@@ -16,10 +16,12 @@ |
// some things. |
+ (NSApplication*)sharedApplication { |
NSApplication* app = [super sharedApplication]; |
- if (![NSApp isKindOfClass:self]) { |
- DLOG(ERROR) << "NSApp should be of type " << [[self className] UTF8String] |
- << ", not " << [[NSApp className] UTF8String]; |
- DCHECK(false) << "NSApp is of wrong type"; |
+ if (![app conformsToProtocol:@protocol(CrAppControlProtocol)]) { |
+ // TODO(shess): This is necessary until all of the references to |
+ // CrApplication are removed. |
+ DLOG(ERROR) << "Existing NSApp (class " << [[app className] UTF8String] |
+ << ") does not conform to required protocol."; |
+ NOTREACHED(); |
} |
return app; |
} |