title: asiHttpRequest under iOS5
body: <p>I am succesfuly using AsiHttpRequest library to make url connections in my apps. However, I upgrade to iOS5 and Reachability.m file is reporting some errors (4) on following functions:</p>
  
  <pre><code>static void ReachabilityCallback(SCNetworkReachabilityRef target, SCNetworkReachabilityFlags flags, void* info) {
  
      #pragma unused (target, flags)
      NSCAssert(info, @"info was NULL in ReachabilityCallback");
      NSCAssert([(NSObject*) info isKindOfClass: [Reachability class]], @"info was the wrong class in ReachabilityCallback");
  
  
      // Post a notification to notify the client that the network reachability changed.
      [[NSNotificationCenter defaultCenter] postNotificationName: kReachabilityChangedNotification object: (Reachability *) info];
  
  
  } // ReachabilityCallback()
  
  
  - (BOOL) startNotifier {
  
      SCNetworkReachabilityContext    context = {0, self, NULL, NULL, NULL};
  
      if(SCNetworkReachabilitySetCallback(reachabilityRef, ReachabilityCallback, &amp;context)) {
  
          if(SCNetworkReachabilityScheduleWithRunLoop(reachabilityRef, CFRunLoopGetCurrent(), kCFRunLoopDefaultMode)) {
  
              return YES;
  
          }
  
      }
  
      return NO;
  
  } // startNotifier
  </code></pre>
  
  <p>1sr error: in NSCAssert line, "Cast of C pointer type 'void' to Objective-C pointer type NSObject requires a bridged cast". Why happens and how to solve it? </p>
  
  <p>ANSWER: you can disable ARC for each file. Go to build settings of your project and set the -fno-objc-arc flag on all the ASIHTTPRequest files (double click to edit text). Then you must remove ASIAuthenticationDialog and any references to it that are still generating errors. It works for me.</p>