title: android app failed to get content at 80 port with HttpClient
body: <p>I want to develop an android app to get post.xml with HttpClient. But it failed to get content with 80 port. </p>
  
  <p>If I start the web server(WEBrick here) with 3000 port, the URI is <a href="http://192.168.1.103:3000/posts.xml" rel="nofollow">http://192.168.1.103:3000/posts.xml</a>;
  Android App can get response with correct length, like 568;</p>
  
  <p>The same web files, I started them with another server (Nignx here) with 80 port, the uri is 
  "http://192.168.1.103/posts.xml; The Android App can NOT get content with length, it's -1 here.<br>
  This URI can be opened with browser(both PC and android emulator) correctly. Furthermore, the response is "HTTP/1.1 200 OK" with responsep.getStatusLine(). </p>
  
  <p>is it related with "Socket ports below 1024 can NOT access in linux like system", which is on
  <a href="http://groups.google.com/group/android-developers/browse_thread/thread/660123ca64ba1229#" rel="nofollow">http://groups.google.com/group/android-developers/browse_thread/thread/660123ca64ba1229#</a></p>
  
  <p>Any Ninja can tell me what should I do if I can to get content with 80 port? </p>
  
  <p>The following is my code. </p>
  
  <p>public class AndroidWorldActivity extends Activity {
      /** Called when the activity is first created. */</p>
  
  <pre><code>TextView tv; 
  
  @Override
  public void onCreate(Bundle savedInstanceState) {
      super.onCreate(savedInstanceState);        
      retreiveProjects();
  }
  
  
  private void retreiveProjects()
  {
    HttpClient httpClient = new DefaultHttpClient();
    try
    {
      String url3000 = "http://192.168.1.103:3000/posts.xml";
      String url = "http://192.168.1.103/posts.xml";
  
      Log.d( "posts", "performing get " + url3000);
      HttpGet httpGet=new HttpGet(url3000);
  
      HttpResponse responsep=httpClient.execute(httpGet);        
      System.out.println(responsep.getStatusLine());
  
      HttpEntity httpEntity = responsep.getEntity();
      int length = ( int ) httpEntity.getContentLength();
  </code></pre>
  
  <p>// print the lenght of content</p>
  
  <pre><code>    System.out.println("The content length is: "+length);
      Log.d( "posts", "The content length is: " + length );
  </code></pre>