Index: base/platform_thread_mac.mm |
diff --git a/base/platform_thread_mac.mm b/base/platform_thread_mac.mm |
index 34afea7c1efef6ab37eaf076d8352587e8a02f1e..36e08be9e86395dcd738a3b1ef930e130f413a49 100644 |
--- a/base/platform_thread_mac.mm |
+++ b/base/platform_thread_mac.mm |
@@ -9,21 +9,6 @@ |
#include "base/logging.h" |
-// A simple class that demonstrates our impressive ability to do nothing. |
-@interface NoOp : NSObject |
- |
-// Does the deed. Or does it? |
-+ (void)noOp; |
- |
-@end |
- |
-@implementation NoOp |
- |
-+ (void)noOp { |
-} |
- |
-@end |
- |
namespace base { |
// If Cocoa is to be used on more than one thread, it must know that the |
@@ -37,8 +22,9 @@ namespace base { |
void InitThreading() { |
static BOOL multithreaded = [NSThread isMultiThreaded]; |
if (!multithreaded) { |
- [NSThread detachNewThreadSelector:@selector(noOp) |
- toTarget:[NoOp class] |
+ // +[NSObject class] is idempotent. |
+ [NSThread detachNewThreadSelector:@selector(class) |
+ toTarget:[NSObject class] |
withObject:nil]; |
multithreaded = YES; |