浏览代码

fix crash by background notification due to wrong unrecognized selector name

Tobias Conradi 9 年之前
父节点
当前提交
f1cd8053f9
共有 1 个文件被更改,包括 2 次插入2 次删除
  1. 2 2
      Sources/VLCLocalServerDiscoveryController.m

+ 2 - 2
Sources/VLCLocalServerDiscoveryController.m

@@ -156,12 +156,12 @@ typedef NS_ENUM(NSUInteger, VLCLocalServerSections) {
     NSNotificationCenter *defaultCenter = [NSNotificationCenter defaultCenter];
 
     [defaultCenter addObserver:self
-                      selector:@selector(applicationWillResignActive:)
+                      selector:@selector(stopDiscovery)
                           name:UIApplicationWillResignActiveNotification
                         object:[UIApplication sharedApplication]];
 
     [defaultCenter addObserver:self
-                      selector:@selector(applicationDidBecomeActive:)
+                      selector:@selector(startDiscovery:)
                           name:UIApplicationDidBecomeActiveNotification
                         object:[UIApplication sharedApplication]];