Program: 44243
Project: 44243
Buggy source:
public void run(){
  int reconnect_delay=0;
  String reason="String_Node_Str";
  do {
    if (getConsumerState() == StreamConsumer.STATE_RUNNING && reconnect_delay > 0) {
      try {
        Thread.sleep(reconnect_delay * 1000);
      }
 catch (      Exception e) {
      }
    }
    BufferedReader reader=null;
    if (getConsumerState() == StreamConsumer.STATE_RUNNING) {
      try {
        DefaultHttpClient client=new DefaultHttpClient();
        HttpGet get=new HttpGet("String_Node_Str" + _user.getStreamBaseURL() + _definition.getHash());
        get.addHeader("String_Node_Str",_user.getUsername() + "String_Node_Str" + _user.getAPIKey());
        HttpResponse response=client.execute(get);
        int statusCode=response.getStatusLine().getStatusCode();
        if (statusCode == 200) {
          reconnect_delay=0;
          reader=new BufferedReader(new InputStreamReader(response.getEntity().getContent()));
          while (getConsumerState() == StreamConsumer.STATE_RUNNING) {
            String line=reader.readLine();
            if (line == null) {
              break;
            }
 else             if (line.length() > 100) {
              processLine(line);
            }
          }
        }
 else         if (statusCode == 404) {
          reason="String_Node_Str";
          _consumer.stop();
        }
 else {
          if (reconnect_delay == 0) {
            reconnect_delay=10;
          }
 else           if (reconnect_delay < 240) {
            reconnect_delay*=2;
          }
 else {
            reason="String_Node_Str" + statusCode + "String_Node_Str"+ response.getStatusLine().getReasonPhrase();
            _consumer.stop();
          }
        }
      }
 catch (      Exception e) {
        reason="String_Node_Str";
      }
    }
    if (reason.length() == 0 && getConsumerState() == StreamConsumer.STATE_RUNNING && _auto_reconnect) {
      if (reconnect_delay == 0) {
        reconnect_delay=1;
      }
 else       if (reconnect_delay < 16) {
        reconnect_delay++;
      }
 else {
        reason="String_Node_Str";
        stopConsumer();
      }
    }
    if (reader != null) {
      try {
        reader.close();
      }
 catch (      IOException e) {
      }
    }
  }
 while (getConsumerState() == StreamConsumer.STATE_RUNNING && _auto_reconnect);
  if (reason.length() == 0) {
    if (getConsumerState() == StreamConsumer.STATE_STOPPING) {
      reason="String_Node_Str";
    }
 else {
      reason="String_Node_Str";
    }
  }
  onStopped(reason);
}

Fixed version (ground truth):
public void run(){
  int reconnect_delay=0;
  String reason="String_Node_Str";
  do {
    if (getConsumerState() == StreamConsumer.STATE_RUNNING && reconnect_delay > 0) {
      try {
        Thread.sleep(reconnect_delay * 1000);
      }
 catch (      Exception e) {
      }
    }
    BufferedReader reader=null;
    if (getConsumerState() == StreamConsumer.STATE_RUNNING) {
      DefaultHttpClient client=new DefaultHttpClient();
      try {
        HttpGet get=new HttpGet("String_Node_Str" + _user.getStreamBaseURL() + _definition.getHash());
        try {
          get.addHeader("String_Node_Str",_user.getUsername() + "String_Node_Str" + _user.getAPIKey());
          HttpResponse response=client.execute(get);
          int statusCode=response.getStatusLine().getStatusCode();
          if (statusCode == 200) {
            reconnect_delay=0;
            reader=new BufferedReader(new InputStreamReader(response.getEntity().getContent()));
            while (getConsumerState() == StreamConsumer.STATE_RUNNING) {
              String line=reader.readLine();
              if (line == null) {
                break;
              }
 else               if (line.length() > 100) {
                processLine(line);
              }
            }
          }
 else           if (statusCode == 404) {
            reason="String_Node_Str";
            _consumer.stop();
          }
 else {
            if (reconnect_delay == 0) {
              reconnect_delay=10;
            }
 else             if (reconnect_delay < 240) {
              reconnect_delay*=2;
            }
 else {
              reason="String_Node_Str" + statusCode + "String_Node_Str"+ response.getStatusLine().getReasonPhrase();
              _consumer.stop();
            }
          }
        }
 catch (        Exception e) {
          reason="String_Node_Str";
        }
 finally {
          try {
            get.abort();
            client.getConnectionManager().shutdown();
          }
 catch (          Exception e) {
          }
        }
      }
 catch (      EInvalidData e) {
        reason=e.getMessage();
        try {
          _consumer.stop();
        }
 catch (        EInvalidData eid) {
        }
      }
catch (      EAccessDenied e) {
        reason=e.getMessage();
        try {
          _consumer.stop();
        }
 catch (        EInvalidData eid) {
        }
      }
    }
    if (reason.length() == 0 && getConsumerState() == StreamConsumer.STATE_RUNNING && _auto_reconnect) {
      if (reconnect_delay == 0) {
        reconnect_delay=1;
      }
 else       if (reconnect_delay < 16) {
        reconnect_delay++;
      }
 else {
        reason="String_Node_Str";
        stopConsumer();
      }
    }
    if (reader != null) {
      try {
        reader.close();
      }
 catch (      IOException e) {
      }
    }
  }
 while (getConsumerState() == StreamConsumer.STATE_RUNNING && _auto_reconnect);
  if (reason.length() == 0) {
    if (getConsumerState() == StreamConsumer.STATE_STOPPING) {
      reason="String_Node_Str";
    }
 else {
      reason="String_Node_Str";
    }
  }
  onStopped(reason);
}