Program: 20154
Project: 20154
Buggy source:
public HistoricalWeather getHistoricalWeather(String data) throws WeatherLibException {
  HistoricalWeather histWeather=new HistoricalWeather();
  try {
    JSONObject jObj=new JSONObject(data);
    JSONArray wList=jObj.getJSONArray("String_Node_Str");
    for (int i=0; i < wList.length(); i++) {
      JSONObject jHour=wList.getJSONObject(i);
      HistoricalHourWeather hhWeather=new HistoricalHourWeather();
      JSONObject cObj=getObject("String_Node_Str",jHour);
      hhWeather.weather.clouds.setPerc(getInt("String_Node_Str",cObj));
      hhWeather.timestamp=jHour.getLong("String_Node_Str") * 1000;
      JSONObject mainObj=getObject("String_Node_Str",jHour);
      hhWeather.weather.currentCondition.setPressure((float)mainObj.getDouble("String_Node_Str"));
      hhWeather.weather.temperature.setTemp((float)mainObj.getDouble("String_Node_Str"));
      hhWeather.weather.temperature.setMaxTemp((float)mainObj.getDouble("String_Node_Str"));
      hhWeather.weather.temperature.setMinTemp((float)mainObj.getDouble("String_Node_Str"));
      JSONObject wObj=jHour.getJSONArray("String_Node_Str").getJSONObject(0);
      hhWeather.weather.currentCondition.setDescr(wObj.getString("String_Node_Str"));
      hhWeather.weather.currentCondition.setIcon(wObj.getString("String_Node_Str"));
      hhWeather.weather.currentCondition.setCondition(wObj.getString("String_Node_Str"));
      hhWeather.weather.currentCondition.setWeatherId(getInt("String_Node_Str",wObj));
      String tmp=String.valueOf(hhWeather.weather.currentCondition.getWeatherId()) + "String_Node_Str";
      if (codeProvider != null)       hhWeather.weather.currentCondition.setWeatherCode(codeProvider.getWeatherCode(String.valueOf(hhWeather.weather.currentCondition.getWeatherId())));
      JSONObject windObj=getObject("String_Node_Str",jHour);
      hhWeather.weather.wind.setSpeed((float)windObj.getDouble("String_Node_Str"));
      hhWeather.weather.wind.setDeg((float)windObj.getDouble("String_Node_Str"));
      histWeather.addHistoricalHourWeather(hhWeather);
    }
  }
 catch (  JSONException json) {
    throw new WeatherLibException(json);
  }
  histWeather.setUnit(units);
  return histWeather;
}

Fixed version (ground truth):
public HistoricalWeather getHistoricalWeather(String data) throws WeatherLibException {
  HistoricalWeather histWeather=new HistoricalWeather();
  try {
    JSONObject jObj=new JSONObject(data);
    JSONArray wList=jObj.getJSONArray("String_Node_Str");
    for (int i=0; i < wList.length(); i++) {
      JSONObject jHour=wList.getJSONObject(i);
      HistoricalHourWeather hhWeather=new HistoricalHourWeather();
      JSONObject cObj=getObject("String_Node_Str",jHour);
      hhWeather.weather.clouds.setPerc(getInt("String_Node_Str",cObj));
      hhWeather.timestamp=jHour.getLong("String_Node_Str") * 1000;
      JSONObject mainObj=getObject("String_Node_Str",jHour);
      hhWeather.weather.currentCondition.setPressure((float)mainObj.getDouble("String_Node_Str"));
      hhWeather.weather.temperature.setTemp((float)mainObj.getDouble("String_Node_Str"));
      hhWeather.weather.temperature.setMaxTemp((float)mainObj.getDouble("String_Node_Str"));
      hhWeather.weather.temperature.setMinTemp((float)mainObj.getDouble("String_Node_Str"));
      JSONObject wObj=jHour.getJSONArray("String_Node_Str").getJSONObject(0);
      hhWeather.weather.currentCondition.setDescr(wObj.getString("String_Node_Str"));
      hhWeather.weather.currentCondition.setIcon(wObj.getString("String_Node_Str"));
      hhWeather.weather.currentCondition.setCondition(wObj.getString("String_Node_Str"));
      hhWeather.weather.currentCondition.setWeatherId(getInt("String_Node_Str",wObj));
      String tmp=String.valueOf(hhWeather.weather.currentCondition.getWeatherId()) + "String_Node_Str";
      if (codeProvider != null) {
        try {
          hhWeather.weather.currentCondition.setWeatherCode(codeProvider.getWeatherCode(String.valueOf(hhWeather.weather.currentCondition.getWeatherId())));
        }
 catch (        Throwable t) {
          hhWeather.weather.currentCondition.setWeatherCode(WeatherCode.NOT_AVAILABLE);
        }
      }
      JSONObject windObj=getObject("String_Node_Str",jHour);
      hhWeather.weather.wind.setSpeed((float)windObj.getDouble("String_Node_Str"));
      hhWeather.weather.wind.setDeg((float)windObj.getDouble("String_Node_Str"));
      histWeather.addHistoricalHourWeather(hhWeather);
    }
  }
 catch (  JSONException json) {
    throw new WeatherLibException(json);
  }
  histWeather.setUnit(units);
  return histWeather;
}