Merge pull request #105 from nickgravelyn/fix-crash-in-ios-unit-test

Prevent GWS_DNOT_REACHED when there is no application
This commit is contained in:
Pierre-Olivier Latour
2014-11-19 08:31:56 +09:00
+1 -1
View File
@@ -283,7 +283,7 @@ static void _ExecuteMainThreadRunLoopSources() {
[[UIApplication sharedApplication] endBackgroundTask:_backgroundTask];
_backgroundTask = UIBackgroundTaskInvalid;
GWS_LOG_DEBUG(@"Did end background task");
} else {
} else if ([UIApplication sharedApplication]) {
GWS_DNOT_REACHED();
}
}