网络不可用时发出警报
- (void)reachabilityChanged:(NSNotification *)note {
Reachability* reachability = [note object];
NetworkStatus netStatus = [reachability currentReachabilityStatus];
if (netStatus == NotReachable) {
NSLog(@"Network unavailable");
}
}