Program: 115347
Project: 115347
Buggy source:
@Override protected void processRequest() throws Exception {
  FormProcessor fp=new FormProcessor(request);
  int oneSubjectId=fp.getInt("String_Node_Str");
  session.setAttribute("String_Node_Str",oneSubjectId);
  int resolutionStatusSubj=fp.getInt(RESOLUTION_STATUS);
  int discNoteType=fp.getInt(TYPE);
  boolean removeSession=fp.getBoolean("String_Node_Str");
  String module=fp.getString("String_Node_Str");
  request.setAttribute("String_Node_Str",module);
  session.setAttribute("String_Node_Str",module);
  String viewForOne=fp.getString("String_Node_Str");
  boolean isForOneSubjectsNotes="String_Node_Str".equalsIgnoreCase(viewForOne);
  DiscrepancyNoteDAO dndao=new DiscrepancyNoteDAO(sm.getDataSource());
  StudyDAO studyDAO=new StudyDAO(sm.getDataSource());
  dndao.setFetchMapping(true);
  String resolutionStatus=fp.getString(RESOLUTION_STATUS);
  if (removeSession) {
    session.removeAttribute(WIN_LOCATION);
    session.removeAttribute(NOTES_TABLE);
  }
  session.setAttribute(WIN_LOCATION,"String_Node_Str" + viewForOne + "String_Node_Str"+ oneSubjectId+ "String_Node_Str"+ module+ "String_Node_Str");
  StudySubjectDAO subdao=new StudySubjectDAO(sm.getDataSource());
  StudyDAO studyDao=new StudyDAO(sm.getDataSource());
  SubjectDAO sdao=new SubjectDAO(sm.getDataSource());
  UserAccountDAO uadao=new UserAccountDAO(sm.getDataSource());
  CRFVersionDAO crfVersionDao=new CRFVersionDAO(sm.getDataSource());
  CRFDAO crfDao=new CRFDAO(sm.getDataSource());
  StudyEventDAO studyEventDao=new StudyEventDAO(sm.getDataSource());
  StudyEventDefinitionDAO studyEventDefinitionDao=new StudyEventDefinitionDAO(sm.getDataSource());
  EventDefinitionCRFDAO eventDefinitionCRFDao=new EventDefinitionCRFDAO(sm.getDataSource());
  ItemDataDAO itemDataDao=new ItemDataDAO(sm.getDataSource());
  ItemDAO itemDao=new ItemDAO(sm.getDataSource());
  EventCRFDAO eventCRFDao=new EventCRFDAO(sm.getDataSource());
  ListNotesTableFactory factory=new ListNotesTableFactory();
  factory.setSubjectDao(sdao);
  factory.setStudySubjectDao(subdao);
  factory.setUserAccountDao(uadao);
  factory.setStudyDao(studyDao);
  factory.setCurrentStudy(currentStudy);
  factory.setDiscrepancyNoteDao(dndao);
  factory.setCrfDao(crfDao);
  factory.setCrfVersionDao(crfVersionDao);
  factory.setStudyEventDao(studyEventDao);
  factory.setStudyEventDefinitionDao(studyEventDefinitionDao);
  factory.setEventDefinitionCRFDao(eventDefinitionCRFDao);
  factory.setItemDao(itemDao);
  factory.setItemDataDao(itemDataDao);
  factory.setEventCRFDao(eventCRFDao);
  String viewNotesHtml=factory.createTable(request,response).render();
  request.setAttribute("String_Node_Str",viewNotesHtml);
  if ("String_Node_Str".equalsIgnoreCase(fp.getString(PRINT))) {
    request.setAttribute("String_Node_Str",factory.getAllNotes());
    forwardPage(Page.VIEW_DISCREPANCY_NOTES_IN_STUDY_PRINT);
  }
 else {
    forwardPage(Page.VIEW_DISCREPANCY_NOTES_IN_STUDY);
  }
}

Fixed version (ground truth):
@Override protected void processRequest() throws Exception {
  String module=request.getParameter("String_Node_Str");
  String moduleStr="String_Node_Str";
  if (module != null && module.trim().length() > 0) {
    if ("String_Node_Str".equals(module)) {
      request.setAttribute("String_Node_Str","String_Node_Str");
      moduleStr="String_Node_Str";
    }
 else     if ("String_Node_Str".equals(module)) {
      request.setAttribute("String_Node_Str","String_Node_Str");
      moduleStr="String_Node_Str";
    }
 else {
      request.setAttribute("String_Node_Str","String_Node_Str");
    }
  }
  FormProcessor fp=new FormProcessor(request);
  int oneSubjectId=fp.getInt("String_Node_Str");
  session.setAttribute("String_Node_Str",oneSubjectId);
  int resolutionStatusSubj=fp.getInt(RESOLUTION_STATUS);
  int discNoteType=0;
  try {
    discNoteType=Integer.parseInt(request.getParameter("String_Node_Str"));
  }
 catch (  NumberFormatException nfe) {
    discNoteType=-1;
  }
  request.setAttribute(DISCREPANCY_NOTE_TYPE,discNoteType);
  boolean removeSession=fp.getBoolean("String_Node_Str");
  session.setAttribute("String_Node_Str",module);
  String viewForOne=fp.getString("String_Node_Str");
  boolean isForOneSubjectsNotes="String_Node_Str".equalsIgnoreCase(viewForOne);
  DiscrepancyNoteDAO dndao=new DiscrepancyNoteDAO(sm.getDataSource());
  StudyDAO studyDAO=new StudyDAO(sm.getDataSource());
  dndao.setFetchMapping(true);
  int resolutionStatus=0;
  try {
    resolutionStatus=Integer.parseInt(request.getParameter("String_Node_Str"));
  }
 catch (  NumberFormatException nfe) {
    resolutionStatus=-1;
  }
  if (removeSession) {
    session.removeAttribute(WIN_LOCATION);
    session.removeAttribute(NOTES_TABLE);
  }
  session.setAttribute(WIN_LOCATION,"String_Node_Str" + viewForOne + "String_Node_Str"+ oneSubjectId+ "String_Node_Str"+ module+ "String_Node_Str");
  StudySubjectDAO subdao=new StudySubjectDAO(sm.getDataSource());
  StudyDAO studyDao=new StudyDAO(sm.getDataSource());
  SubjectDAO sdao=new SubjectDAO(sm.getDataSource());
  UserAccountDAO uadao=new UserAccountDAO(sm.getDataSource());
  CRFVersionDAO crfVersionDao=new CRFVersionDAO(sm.getDataSource());
  CRFDAO crfDao=new CRFDAO(sm.getDataSource());
  StudyEventDAO studyEventDao=new StudyEventDAO(sm.getDataSource());
  StudyEventDefinitionDAO studyEventDefinitionDao=new StudyEventDefinitionDAO(sm.getDataSource());
  EventDefinitionCRFDAO eventDefinitionCRFDao=new EventDefinitionCRFDAO(sm.getDataSource());
  ItemDataDAO itemDataDao=new ItemDataDAO(sm.getDataSource());
  ItemDAO itemDao=new ItemDAO(sm.getDataSource());
  EventCRFDAO eventCRFDao=new EventCRFDAO(sm.getDataSource());
  ListNotesTableFactory factory=new ListNotesTableFactory();
  factory.setSubjectDao(sdao);
  factory.setStudySubjectDao(subdao);
  factory.setUserAccountDao(uadao);
  factory.setStudyDao(studyDao);
  factory.setCurrentStudy(currentStudy);
  factory.setDiscrepancyNoteDao(dndao);
  factory.setCrfDao(crfDao);
  factory.setCrfVersionDao(crfVersionDao);
  factory.setStudyEventDao(studyEventDao);
  factory.setStudyEventDefinitionDao(studyEventDefinitionDao);
  factory.setEventDefinitionCRFDao(eventDefinitionCRFDao);
  factory.setItemDao(itemDao);
  factory.setItemDataDao(itemDataDao);
  factory.setEventCRFDao(eventCRFDao);
  factory.setModule(moduleStr);
  factory.setDiscNoteType(discNoteType);
  factory.setResolutionStatus(resolutionStatus);
  String viewNotesHtml=factory.createTable(request,response).render();
  request.setAttribute("String_Node_Str",viewNotesHtml);
  if ("String_Node_Str".equalsIgnoreCase(fp.getString(PRINT))) {
    request.setAttribute("String_Node_Str",factory.getAllNotes());
    forwardPage(Page.VIEW_DISCREPANCY_NOTES_IN_STUDY_PRINT);
  }
 else {
    forwardPage(Page.VIEW_DISCREPANCY_NOTES_IN_STUDY);
  }
}