title: why does the okhttp program dosen`t stucked in while(true)?
body: <p>Recently i am reading the source code in OKHTTP and found that in RetryAndFollowUpInterceptor.java has a while(true) recycle. But, the program dose not stacked in that place or occur 'Application not responding'.Then I attached the debugger and put a breakpoint in that place and found it is running in main thread.I don<code>t know why the program runs normal at all.Who can help me? 
  Thanks to stephenC</code>s answer, but you might not get my point.In my question I mean why does the program not stuck in while(true) recycle in main thread.
  For example, if there is a while(true) recycle in activity`s onCreate() lifecycle, the app might not run correctly ,just stuck in that place and can not respond touch event, which means the application not responding(ANR).
  How will the recycle exit?
  The following is the source code:</p>
  
  <pre><code>@Override
  public Response intercept(Chain chain) throws IOException {
      ...
      //This is the start of the recycle!Just recycle forever
      while (true) {
        if (canceled) {
          streamAllocation.release();
          throw new IOException("Canceled");
        }
  
        Response response;
        boolean releaseConnection = true;
        try {
          response = realChain.proceed(request, streamAllocation, null, null);
          releaseConnection = false;
        } catch (RouteException e) {
          // The attempt to connect via a route failed. The request will not have been sent.
          if (!recover(e.getLastConnectException(), streamAllocation, false, request)) {
            throw e.getFirstConnectException();
          }
          releaseConnection = false;
          continue;
        } catch (IOException e) {
          // An attempt to communicate with a server failed. The request may have been sent.
          boolean requestSendStarted = !(e instanceof ConnectionShutdownException);
          if (!recover(e, streamAllocation, requestSendStarted, request)) throw e;
          releaseConnection = false;
          continue;
        } finally {
          // We're throwing an unchecked exception. Release any resources.
          if (releaseConnection) {
            streamAllocation.streamFailed(null);
            streamAllocation.release();
          }
  ...
        }
      }
    }
  </code></pre>