nus-yam/ex-repair huggingface dataset:
Program: 52574
Project: 52574
Buggy source:
private void replaceItems(Context c,Collection mycollection,String sourceDir,String mapFile) throws Exception {
  HashMap myhash=readMapFile(mapFile);
  Iterator i=myhash.keySet().iterator();
  ArrayList itemsToDelete=new ArrayList();
  while (i.hasNext()) {
    String newItemName=(String)i.next();
    String oldHandle=(String)myhash.get(newItemName);
    System.out.println("String_Node_Str" + oldHandle);
    Item oldItem=(Item)HandleManager.resolveToObject(c,oldHandle);
    Item newItem=addItem(c,mycollection,sourceDir,newItemName,null);
    String newHandle=HandleManager.findHandle(c,newItem);
    String myquery="String_Node_Str" + Constants.ITEM + "String_Node_Str"+ newItem.getID();
    DatabaseManager.updateQuery(c,myquery);
    myquery="String_Node_Str" + newItem.getID() + "String_Node_Str"+ oldHandle+ "String_Node_Str";
    DatabaseManager.updateQuery(c,myquery);
    itemsToDelete.add(oldItem);
  }
  i=itemsToDelete.iterator();
  while (i.hasNext()) {
    removeItem(c,(Item)i.next());
  }
}

Fixed version (ground truth):
private void replaceItems(Context c,Collection mycollection,String sourceDir,String mapFile) throws Exception {
  HashMap myhash=readMapFile(mapFile);
  Iterator i=myhash.keySet().iterator();
  ArrayList itemsToDelete=new ArrayList();
  while (i.hasNext()) {
    String newItemName=(String)i.next();
    String oldHandle=(String)myhash.get(newItemName);
    System.out.println("String_Node_Str" + oldHandle);
    Item oldItem=(Item)HandleManager.resolveToObject(c,oldHandle);
    Item newItem=addItem(c,mycollection,sourceDir,newItemName,oldHandle,null);
    itemsToDelete.add(oldItem);
  }
  i=itemsToDelete.iterator();
  while (i.hasNext()) {
    removeItem(c,(Item)i.next());
  }
}
Program: 52575
Project: 52575
Buggy source:
private Item addItem(Context c,Collection mycollection,String path,String itemname,PrintWriter mapOut) throws Exception {
  Item myitem=null;
  System.out.println("String_Node_Str" + itemname);
  WorkspaceItem wi=WorkspaceItem.create(c,mycollection,false);
  myitem=wi.getItem();
  loadDublinCore(c,myitem,path + "String_Node_Str" + itemname+ "String_Node_Str"+ "String_Node_Str");
  processContentsFile(c,myitem,path + "String_Node_Str" + itemname,"String_Node_Str");
  String myhandle=processHandleFile(c,myitem,path + "String_Node_Str" + itemname,"String_Node_Str");
  InstallItem.installItem(c,wi,myhandle);
  myhandle=HandleManager.findHandle(c,myitem);
  if (mapOut != null) {
    mapOut.println(itemname + "String_Node_Str" + myhandle);
  }
  return myitem;
}

Fixed version (ground truth):
/** 
 * item?  try and add it to the archive c mycollection path itemname  handle - non-null means we have a pre-defined handle already mapOut - mapfile we're writing
 */
private Item addItem(Context c,Collection mycollection,String path,String itemname,String handle,PrintWriter mapOut) throws Exception {
  Item myitem=null;
  System.out.println("String_Node_Str" + itemname);
  WorkspaceItem wi=WorkspaceItem.create(c,mycollection,false);
  myitem=wi.getItem();
  loadDublinCore(c,myitem,path + "String_Node_Str" + itemname+ "String_Node_Str"+ "String_Node_Str");
  processContentsFile(c,myitem,path + "String_Node_Str" + itemname,"String_Node_Str");
  String myhandle=processHandleFile(c,myitem,path + "String_Node_Str" + itemname,"String_Node_Str");
  InstallItem.installItem(c,wi,myhandle);
  myhandle=HandleManager.findHandle(c,myitem);
  if (mapOut != null) {
    mapOut.println(itemname + "String_Node_Str" + myhandle);
  }
  return myitem;
}
Program: 52576
Project: 52576
Buggy source:
private void addDCValue(Item i,Node n) throws TransformerException {
  String value=getStringValue(n);
  String element=getAttributeValue(n,"String_Node_Str");
  String qualifier=getAttributeValue(n,"String_Node_Str");
  System.out.println("String_Node_Str" + element + "String_Node_Str"+ qualifier+ "String_Node_Str"+ value);
  if (qualifier.equals("String_Node_Str"))   qualifier=null;
  i.addDC(element,qualifier,"String_Node_Str",value);
}

Fixed version (ground truth):
private void addDCValue(Item i,Node n) throws TransformerException {
  String value=getStringValue(n);
  String element=getAttributeValue(n,"String_Node_Str");
  String qualifier=getAttributeValue(n,"String_Node_Str");
  String language=getAttributeValue(n,"String_Node_Str");
  System.out.println("String_Node_Str" + element + "String_Node_Str"+ qualifier+ "String_Node_Str"+ value);
  if (qualifier.equals("String_Node_Str"))   qualifier=null;
  if (language.equals("String_Node_Str")) {
    language=ConfigurationManager.getProperty("String_Node_Str");
  }
  if (language == null) {
    language="String_Node_Str";
  }
  i.addDC(element,qualifier,language,value);
}
Program: 52577
Project: 52577
Buggy source:
private void addItems(Context c,Collection mycollection,String sourceDir,String mapFile) throws Exception {
  System.out.println("String_Node_Str" + sourceDir);
  System.out.println("String_Node_Str" + mapFile);
  File outFile=new File(mapFile);
  PrintWriter mapOut=new PrintWriter(new FileWriter(outFile));
  String[] dircontents=new java.io.File(sourceDir).list();
  for (int i=0; i < dircontents.length; i++) {
    addItem(c,mycollection,sourceDir,dircontents[i],mapOut);
    System.out.println(i + "String_Node_Str" + dircontents[i]);
  }
  mapOut.close();
}

Fixed version (ground truth):
private void addItems(Context c,Collection mycollection,String sourceDir,String mapFile) throws Exception {
  System.out.println("String_Node_Str" + sourceDir);
  System.out.println("String_Node_Str" + mapFile);
  File outFile=new File(mapFile);
  PrintWriter mapOut=new PrintWriter(new FileWriter(outFile));
  String[] dircontents=new java.io.File(sourceDir).list();
  for (int i=0; i < dircontents.length; i++) {
    addItem(c,mycollection,sourceDir,dircontents[i],null,mapOut);
    System.out.println(i + "String_Node_Str" + dircontents[i]);
  }
  mapOut.close();
}
Program: 52579
Project: 52579
Buggy source:
private static void recordApproval(Context c,WorkflowItem wi,EPerson e) throws SQLException, AuthorizeException {
  Item item=wi.getItem();
  String usersName=getEPersonName(e);
  String now=DCDate.getCurrent().toString();
  String provDescription="String_Node_Str" + usersName + "String_Node_Str"+ now+ "String_Node_Str";
  provDescription+=InstallItem.getBitstreamProvenanceMessage(item);
  item.addDC("String_Node_Str","String_Node_Str",null,provDescription);
  item.update();
}

Fixed version (ground truth):
private static void recordApproval(Context c,WorkflowItem wi,EPerson e) throws SQLException, AuthorizeException {
  Item item=wi.getItem();
  String usersName=getEPersonName(e);
  String now=DCDate.getCurrent().toString();
  String provDescription="String_Node_Str" + usersName + "String_Node_Str"+ now+ "String_Node_Str";
  provDescription+=InstallItem.getBitstreamProvenanceMessage(item);
  item.addDC("String_Node_Str","String_Node_Str","String_Node_Str",provDescription);
  item.update();
}
Program: 52580
Project: 52580
Buggy source:
/** 
 * rejects an item - rejection means undoing a submit - WorkspaceItem is created, and the WorkflowItem is removed, user is emailed rejection_message.
 * @param c  Context
 * @param wi WorkflowItem to operate on
 * @param e  EPerson doing the operation
 * @param rejection_message message to email to user
 */
public static WorkspaceItem reject(Context c,WorkflowItem wi,EPerson e,String rejection_message) throws SQLException, AuthorizeException, IOException {
  deleteTasks(c,wi);
  Item myitem=wi.getItem();
  String now=DCDate.getCurrent().toString();
  String usersName=getEPersonName(e);
  String provDescription="String_Node_Str" + usersName + "String_Node_Str"+ rejection_message+ "String_Node_Str"+ now+ "String_Node_Str";
  myitem.addDC("String_Node_Str","String_Node_Str",null,provDescription);
  myitem.update();
  WorkspaceItem wsi=returnToWorkspace(c,wi);
  notifyOfReject(c,wi,e,rejection_message);
  log.info(LogManager.getHeader(c,"String_Node_Str","String_Node_Str" + wi.getID() + "String_Node_Str"+ wi.getItem().getID()+ "String_Node_Str"+ wi.getCollection().getID()+ "String_Node_Str"+ e.getID()));
  return wsi;
}

Fixed version (ground truth):
/** 
 * rejects an item - rejection means undoing a submit - WorkspaceItem is created, and the WorkflowItem is removed, user is emailed rejection_message.
 * @param c  Context
 * @param wi WorkflowItem to operate on
 * @param e  EPerson doing the operation
 * @param rejection_message message to email to user
 */
public static WorkspaceItem reject(Context c,WorkflowItem wi,EPerson e,String rejection_message) throws SQLException, AuthorizeException, IOException {
  deleteTasks(c,wi);
  Item myitem=wi.getItem();
  String now=DCDate.getCurrent().toString();
  String usersName=getEPersonName(e);
  String provDescription="String_Node_Str" + usersName + "String_Node_Str"+ rejection_message+ "String_Node_Str"+ now+ "String_Node_Str";
  myitem.addDC("String_Node_Str","String_Node_Str","String_Node_Str",provDescription);
  myitem.update();
  WorkspaceItem wsi=returnToWorkspace(c,wi);
  notifyOfReject(c,wi,e,rejection_message);
  log.info(LogManager.getHeader(c,"String_Node_Str","String_Node_Str" + wi.getID() + "String_Node_Str"+ wi.getItem().getID()+ "String_Node_Str"+ wi.getCollection().getID()+ "String_Node_Str"+ e.getID()));
  return wsi;
}
Program: 52582
Project: 52582
Buggy source:
/** 
 * Return the file corresponding to ID, or null.
 * @param bitstream  the table row for the bitstream
 * @return The file corresponding to ID, or null
 * @exception IOException If a problem occurs while determining the file
 */
private static File getFile(TableRow bitstream) throws IOException {
  int storeNumber=bitstream.getIntColumn("String_Node_Str");
  if (storeNumber == -1) {
    storeNumber=0;
  }
  File store=assetStores[storeNumber];
  String id=bitstream.getStringColumn("String_Node_Str");
  BigInteger bigint=new BigInteger(id);
  StringBuffer result=new StringBuffer().append(store.getCanonicalPath());
  for (int i=0; i < directoryLevels; i++) {
    int digits=i * digitsPerLevel;
    result.append(File.separator).append(id.substring(digits,digits + digitsPerLevel));
  }
  String theName=result.append(File.separator).append(id).toString();
  if (log.isDebugEnabled())   log.debug("String_Node_Str" + id + "String_Node_Str"+ theName);
  return new File(theName);
}

Fixed version (ground truth):
/** 
 * Return the file corresponding to a bitstream.  It's safe to pass in <code>null</code>.
 * @param bitstream  the database table row for the bitstream.Can be <code>null</code>
 * @return  The corresponding file in the file system, or <code>null</code>
 * @exception IOException If a problem occurs while determining the file
 */
private static File getFile(TableRow bitstream) throws IOException {
  if (bitstream == null) {
    return null;
  }
  int storeNumber=bitstream.getIntColumn("String_Node_Str");
  if (storeNumber == -1) {
    storeNumber=0;
  }
  File store=assetStores[storeNumber];
  String id=bitstream.getStringColumn("String_Node_Str");
  BigInteger bigint=new BigInteger(id);
  StringBuffer result=new StringBuffer().append(store.getCanonicalPath());
  for (int i=0; i < directoryLevels; i++) {
    int digits=i * digitsPerLevel;
    result.append(File.separator).append(id.substring(digits,digits + digitsPerLevel));
  }
  String theName=result.append(File.separator).append(id).toString();
  if (log.isDebugEnabled())   log.debug("String_Node_Str" + id + "String_Node_Str"+ theName);
  return new File(theName);
}
Program: 52585
Project: 52585
Buggy source:
/** 
 * Create an empty template item for this collection.  If one already exists, no action is taken.  Caution:  Make sure you call <code>update</code> on the collection after doing this, or the item will have been created but the collection record will not refer to it.
 */
public void createTemplateItem() throws SQLException, AuthorizeException {
  AuthorizeManager.authorizeAction(ourContext,this,Constants.WRITE);
  if (template == null) {
    template=Item.create(ourContext);
    log.info(LogManager.getHeader(ourContext,"String_Node_Str","String_Node_Str" + getID() + "String_Node_Str"+ template.getID()));
  }
}

Fixed version (ground truth):
/** 
 * Create an empty template item for this collection.  If one already exists, no action is taken.  Caution:  Make sure you call <code>update</code> on the collection after doing this, or the item will have been created but the collection record will not refer to it.
 */
public void createTemplateItem() throws SQLException, AuthorizeException {
  AuthorizeManager.authorizeAction(ourContext,this,Constants.WRITE);
  if (template == null) {
    template=Item.create(ourContext);
    collectionRow.setColumn("String_Node_Str",template.getID());
    log.info(LogManager.getHeader(ourContext,"String_Node_Str","String_Node_Str" + getID() + "String_Node_Str"+ template.getID()));
  }
}
Program: 52586
Project: 52586
Buggy source:
/** 
 * Return the index of the first non-whitespace character in the character array, starting at position STARTAT.
 */
private static int firstWhitespace(char[] title,int startAt){
  int first=0;
  for (int j=startAt; j < title.length; j++) {
    if (Character.isWhitespace(title[j])) {
      first=j + 1;
      continue;
    }
    break;
  }
  return first;
}

Fixed version (ground truth):
/** 
 * Return the index of the first letter or number in the character array, starting at position STARTAT.
 */
private static int firstWhitespace(char[] title,int startAt){
  int first=0;
  for (int j=startAt; j < title.length; j++) {
    if (!Character.isLetterOrDigit(title[j])) {
      first=j + 1;
      continue;
    }
    break;
  }
  return first;
}
Program: 52588
Project: 52588
Buggy source:
/** 
 * List bitstreams in the item
 */
private void listBitstreams() throws IOException {
  JspWriter out=pageContext.getOut();
  HttpServletRequest request=(HttpServletRequest)pageContext.getRequest();
  out.print("String_Node_Str");
  out.println("String_Node_Str");
  Bundle[] bundles=item.getBundles();
  if (bundles.length == 0) {
    out.println("String_Node_Str");
  }
 else {
    out.println("String_Node_Str");
    for (int i=0; i < bundles.length; i++) {
      Bitstream[] bitstreams=bundles[i].getBitstreams();
      for (int k=0; k < bitstreams.length; k++) {
        if (!bitstreams[k].getFormat().isInternal()) {
          out.print("String_Node_Str");
          out.print(bitstreams[k].getName());
          out.print("String_Node_Str");
          out.print(bitstreams[k].getSize() / 1024);
          out.print("String_Node_Str");
          out.print(bitstreams[k].getFormatDescription());
          out.print("String_Node_Str");
          out.print(request.getContextPath());
          out.print("String_Node_Str");
          out.print(bitstreams[k].getID() + "String_Node_Str");
          out.print(URLEncoder.encode(bitstreams[k].getName()));
          out.print("String_Node_Str");
        }
      }
    }
    out.println("String_Node_Str");
  }
  out.println("String_Node_Str");
}

Fixed version (ground truth):
/** 
 * List bitstreams in the item
 */
private void listBitstreams() throws IOException {
  JspWriter out=pageContext.getOut();
  HttpServletRequest request=(HttpServletRequest)pageContext.getRequest();
  out.print("String_Node_Str");
  out.println("String_Node_Str");
  Bundle[] bundles=item.getBundles();
  if (bundles.length == 0) {
    out.println("String_Node_Str");
  }
 else {
    boolean multiFile=(bundles.length > 2);
    out.println("String_Node_Str");
    if (multiFile) {
      out.println("String_Node_Str");
    }
    out.println("String_Node_Str");
    for (int i=0; i < bundles.length; i++) {
      Bitstream[] bitstreams=bundles[i].getBitstreams();
      for (int k=0; k < bitstreams.length; k++) {
        if (!bitstreams[k].getFormat().isInternal()) {
          out.print("String_Node_Str");
          out.print(bitstreams[k].getName());
          if (multiFile) {
            out.print("String_Node_Str");
            String desc=bitstreams[k].getDescription();
            out.print(desc != null ? desc : "String_Node_Str");
          }
          out.print("String_Node_Str");
          out.print(bitstreams[k].getSize() / 1024);
          out.print("String_Node_Str");
          out.print(bitstreams[k].getFormatDescription());
          out.print("String_Node_Str");
          out.print(request.getContextPath());
          out.print("String_Node_Str");
          out.print(bitstreams[k].getID() + "String_Node_Str");
          out.print(URLEncoder.encode(bitstreams[k].getName()));
          out.print("String_Node_Str");
        }
      }
    }
    out.println("String_Node_Str");
  }
  out.println("String_Node_Str");
}
Program: 52592
Project: 52592
Buggy source:
/** 
 * Get the e-person's full name, combining first and last name in a displayable string.
 * @return  their full name
 */
public String getFullName(){
  String t=myRow.getStringColumn("String_Node_Str") + "String_Node_Str" + myRow.getStringColumn("String_Node_Str");
  return t;
}

Fixed version (ground truth):
/** 
 * Get the e-person's full name, combining first and last name in a displayable string.
 * @return  their full name
 */
public String getFullName(){
  String f=myRow.getStringColumn("String_Node_Str");
  String l=myRow.getStringColumn("String_Node_Str");
  if (l == null && f == null) {
    return getEmail();
  }
 else   if (f == null) {
    return l;
  }
 else {
    return (f + "String_Node_Str" + l);
  }
}
Program: 52594
Project: 52594
Buggy source:
/** 
 * Process input from remove item page
 * @param context   current context
 * @param request   current servlet request object
 * @param response  current servlet response object
 */
private void processRemoveItem(Context context,HttpServletRequest request,HttpServletResponse response) throws ServletException, IOException, SQLException, AuthorizeException {
  String buttonPressed=UIUtil.getSubmitButton(request,"String_Node_Str");
  WorkspaceItem workspaceItem;
  try {
    int wsID=Integer.parseInt(request.getParameter("String_Node_Str"));
    workspaceItem=WorkspaceItem.find(context,wsID);
  }
 catch (  NumberFormatException nfe) {
    workspaceItem=null;
  }
  if (workspaceItem == null) {
    log.warn(LogManager.getHeader(context,"String_Node_Str",UIUtil.getRequestLogInfo(request)));
    JSPManager.showIntegrityError(request,response);
    return;
  }
  if (buttonPressed.equals("String_Node_Str")) {
    log.info(LogManager.getHeader(context,"String_Node_Str","String_Node_Str" + workspaceItem.getID() + "String_Node_Str"+ workspaceItem.getItem().getID()));
    workspaceItem.deleteWrapper();
    showMainPage(context,request,response);
    context.complete();
  }
 else {
    showMainPage(context,request,response);
  }
}

Fixed version (ground truth):
/** 
 * Process input from remove item page
 * @param context   current context
 * @param request   current servlet request object
 * @param response  current servlet response object
 */
private void processRemoveItem(Context context,HttpServletRequest request,HttpServletResponse response) throws ServletException, IOException, SQLException, AuthorizeException {
  String buttonPressed=UIUtil.getSubmitButton(request,"String_Node_Str");
  WorkspaceItem workspaceItem;
  try {
    int wsID=Integer.parseInt(request.getParameter("String_Node_Str"));
    workspaceItem=WorkspaceItem.find(context,wsID);
  }
 catch (  NumberFormatException nfe) {
    workspaceItem=null;
  }
  if (workspaceItem == null) {
    log.warn(LogManager.getHeader(context,"String_Node_Str",UIUtil.getRequestLogInfo(request)));
    JSPManager.showIntegrityError(request,response);
    return;
  }
  if (buttonPressed.equals("String_Node_Str")) {
    log.info(LogManager.getHeader(context,"String_Node_Str","String_Node_Str" + workspaceItem.getID() + "String_Node_Str"+ workspaceItem.getItem().getID()));
    workspaceItem.deleteAll();
    showMainPage(context,request,response);
    context.complete();
  }
 else {
    showMainPage(context,request,response);
  }
}
Program: 52595
Project: 52595
Buggy source:
/** 
 * Delete the item.  Bundles and bitstreams are also deleted if they are not also included in another item.  The Dublin Core metadata is deleted.
 */
void delete() throws SQLException, AuthorizeException, IOException {
  AuthorizeManager.authorizeAction(ourContext,this,Constants.DELETE);
  HistoryManager.saveHistory(ourContext,this,HistoryManager.REMOVE,ourContext.getCurrentUser(),ourContext.getExtraLogInfo());
  log.info(LogManager.getHeader(ourContext,"String_Node_Str","String_Node_Str" + getID()));
  ourContext.removeCached(this,getID());
  if (isArchived()) {
    Browse.itemRemoved(ourContext,getID());
  }
  removeDCFromDatabase();
  Bundle[] bundles=getBundles();
  for (int i=0; i < bundles.length; i++) {
    removeBundle(bundles[i]);
  }
  AuthorizeManager.removeAllPolicies(ourContext,this);
  DatabaseManager.updateQuery(ourContext,"String_Node_Str" + Constants.ITEM + "String_Node_Str"+ getID());
  DatabaseManager.delete(ourContext,itemRow);
}

Fixed version (ground truth):
/** 
 * Delete the item.  Bundles and bitstreams are also deleted if they are not also included in another item.  The Dublin Core metadata is deleted.
 */
void delete() throws SQLException, AuthorizeException, IOException {
  HistoryManager.saveHistory(ourContext,this,HistoryManager.REMOVE,ourContext.getCurrentUser(),ourContext.getExtraLogInfo());
  log.info(LogManager.getHeader(ourContext,"String_Node_Str","String_Node_Str" + getID()));
  ourContext.removeCached(this,getID());
  if (isArchived()) {
    Browse.itemRemoved(ourContext,getID());
  }
  removeDCFromDatabase();
  Bundle[] bundles=getBundles();
  for (int i=0; i < bundles.length; i++) {
    removeBundle(bundles[i]);
  }
  AuthorizeManager.removeAllPolicies(ourContext,this);
  DatabaseManager.updateQuery(ourContext,"String_Node_Str" + Constants.ITEM + "String_Node_Str"+ getID());
  DatabaseManager.delete(ourContext,itemRow);
}
Program: 52597
Project: 52597
Buggy source:
protected static int countTotalInIndex(BrowseScope scope,int numberOfResults) throws SQLException {
  int browseType=scope.getBrowseType();
  if ((browseType == ITEMS_BY_AUTHOR_BROWSE) && (scope.hasNoLimit() || ((scope.getTotal() > numberOfResults))))   return numberOfResults;
  PreparedStatement statement=null;
  Object obj=scope.getScope();
  try {
    String table=BrowseTables.getTable(scope);
    StringBuffer buffer=new StringBuffer().append("String_Node_Str").append(getTargetColumns(scope)).append("String_Node_Str").append(table);
    boolean hasWhere=false;
    if (browseType == ITEMS_BY_AUTHOR_BROWSE) {
      hasWhere=true;
      buffer.append("String_Node_Str");
    }
    String connector=hasWhere ? "String_Node_Str" : "String_Node_Str";
    String sql=buffer.append(getScopeClause(scope,connector)).toString();
    if (log.isDebugEnabled())     log.debug("String_Node_Str" + sql + "String_Node_Str");
    statement=createStatement(scope,sql);
    if (browseType == ITEMS_BY_AUTHOR_BROWSE)     statement.setString(1,(String)scope.getFocus());
    return getIntValue(statement);
  }
  finally {
    if (statement != null)     statement.close();
  }
}

Fixed version (ground truth):
protected static int countTotalInIndex(BrowseScope scope,int numberOfResults) throws SQLException {
  int browseType=scope.getBrowseType();
  if ((browseType == ITEMS_BY_AUTHOR_BROWSE) && (scope.hasNoLimit() || ((scope.getTotal() > numberOfResults))))   return numberOfResults;
  PreparedStatement statement=null;
  Object obj=scope.getScope();
  try {
    String table=BrowseTables.getTable(scope);
    StringBuffer buffer=new StringBuffer().append("String_Node_Str").append((getTargetColumns(scope) == "String_Node_Str") ? "String_Node_Str" : "String_Node_Str").append("String_Node_Str").append(table);
    boolean hasWhere=false;
    if (browseType == ITEMS_BY_AUTHOR_BROWSE) {
      hasWhere=true;
      buffer.append("String_Node_Str");
    }
    String connector=hasWhere ? "String_Node_Str" : "String_Node_Str";
    String sql=buffer.append(getScopeClause(scope,connector)).toString();
    if (log.isDebugEnabled())     log.debug("String_Node_Str" + sql + "String_Node_Str");
    statement=createStatement(scope,sql);
    if (browseType == ITEMS_BY_AUTHOR_BROWSE)     statement.setString(1,(String)scope.getFocus());
    return getIntValue(statement);
  }
  finally {
    if (statement != null)     statement.close();
  }
}
Program: 52599
Project: 52599
Buggy source:
/** 
 * Returns a normalized String corresponding to TITLE. The normalization is effected by: + first removing leading spaces, if any + then removing the first leading occurences of "a", "an" and "the" (in any case). + removing any whitespace following an occurence of a stop word This simple strategy is only expected to be used for English words.
 */
public static String normalizeEnglish(String title){
  if (title == null)   return null;
  if (title.length() == 0)   return title;
  int startAt=firstWhitespace(title);
  boolean modified=(startAt != 0);
  boolean usedStopWord=false;
  String stop=null;
  for (int i=0; i < STOP_WORDS.length; i++) {
    stop=STOP_WORDS[i];
    int stoplen=stop.length();
    boolean found=title.toLowerCase().startsWith(stop.toLowerCase(),startAt) && title.length() >= (startAt + stoplen + 1) && Character.isWhitespace(title.charAt(startAt + stoplen));
    if (found) {
      modified=true;
      usedStopWord=true;
      startAt+=stoplen;
      int firstw=firstWhitespace(title,startAt);
      if (firstw != 0)       startAt=firstw;
      break;
    }
  }
  if (!modified)   return title;
  if (!usedStopWord)   return title.substring(startAt);
  return new StringBuffer(title.substring(startAt)).append("String_Node_Str").append(stop).toString();
}

Fixed version (ground truth):
/** 
 * Returns a normalized String corresponding to TITLE. The normalization is effected by: + first removing leading spaces, if any + then removing the first leading occurences of "a", "an" and "the" (in any case). + removing any whitespace following an occurence of a stop word This simple strategy is only expected to be used for English words.
 */
public static String normalizeEnglish(String oldtitle){
  if (oldtitle == null)   return null;
  if (oldtitle.length() == 0)   return oldtitle;
  String title=oldtitle.toLowerCase();
  int startAt=firstWhitespace(title);
  boolean modified=(startAt != 0);
  boolean usedStopWord=false;
  String stop=null;
  for (int i=0; i < STOP_WORDS.length; i++) {
    stop=STOP_WORDS[i];
    int stoplen=stop.length();
    boolean found=title.toLowerCase().startsWith(stop.toLowerCase(),startAt) && title.length() >= (startAt + stoplen + 1) && Character.isWhitespace(title.charAt(startAt + stoplen));
    if (found) {
      modified=true;
      usedStopWord=true;
      startAt+=stoplen;
      int firstw=firstWhitespace(title,startAt);
      if (firstw != 0)       startAt=firstw;
      break;
    }
  }
  if (!modified)   return title;
  if (!usedStopWord)   return title.substring(startAt);
  return new StringBuffer(title.substring(startAt)).append("String_Node_Str").append(stop).toString();
}
Program: 52602
Project: 52602
Buggy source:
/** 
 * Process information from "enter new password"
 * @param context   current DSpace context
 * @param request   current servlet request object
 * @param response  current servlet response object
 */
private void processNewPassword(Context context,HttpServletRequest request,HttpServletResponse response) throws ServletException, IOException, SQLException, AuthorizeException {
  String key=request.getParameter("String_Node_Str");
  EPerson eperson=AccountManager.getEPerson(context,key);
  if (eperson == null) {
    log.info(LogManager.getHeader(context,"String_Node_Str","String_Node_Str" + key));
    JSPManager.showJSP(request,response,"String_Node_Str");
    return;
  }
  boolean passwordOK=EditProfileServlet.confirmAndSetPassword(eperson,request);
  if (passwordOK) {
    log.info(LogManager.getHeader(context,"String_Node_Str","String_Node_Str" + eperson.getEmail()));
    AccountManager.deleteToken(context,key);
    JSPManager.showJSP(request,response,"String_Node_Str");
    context.complete();
  }
 else {
    request.setAttribute("String_Node_Str",new Boolean(true));
    request.setAttribute("String_Node_Str",key);
    request.setAttribute("String_Node_Str",eperson);
    JSPManager.showJSP(request,response,"String_Node_Str");
  }
}

Fixed version (ground truth):
/** 
 * Process information from "enter new password"
 * @param context   current DSpace context
 * @param request   current servlet request object
 * @param response  current servlet response object
 */
private void processNewPassword(Context context,HttpServletRequest request,HttpServletResponse response) throws ServletException, IOException, SQLException, AuthorizeException {
  String key=request.getParameter("String_Node_Str");
  EPerson eperson=AccountManager.getEPerson(context,key);
  if (eperson == null) {
    log.info(LogManager.getHeader(context,"String_Node_Str","String_Node_Str" + key));
    JSPManager.showJSP(request,response,"String_Node_Str");
    return;
  }
  context.setCurrentUser(eperson);
  boolean passwordOK=EditProfileServlet.confirmAndSetPassword(eperson,request);
  if (passwordOK) {
    log.info(LogManager.getHeader(context,"String_Node_Str","String_Node_Str" + eperson.getEmail()));
    AccountManager.deleteToken(context,key);
    JSPManager.showJSP(request,response,"String_Node_Str");
    context.complete();
  }
 else {
    request.setAttribute("String_Node_Str",new Boolean(true));
    request.setAttribute("String_Node_Str",key);
    request.setAttribute("String_Node_Str",eperson);
    JSPManager.showJSP(request,response,"String_Node_Str");
  }
}
Program: 52604
Project: 52604
Buggy source:
/** 
 * Get repeated values from a form.  If "foo" is passed in, values in the form of parameters "foo_0", "foo_1", etc. are returned.
 * @param request   the HTTP request containing the form information
 * @param param     the repeated parameter
 * @return a List of Strings
 */
private List getRepeatedParameter(HttpServletRequest request,String param){
  List vals=new LinkedList();
  int i=0;
  boolean foundLast=false;
  while (!foundLast) {
    String s=request.getParameter(param + "String_Node_Str" + i);
    if (s != null) {
      vals.add(s);
    }
 else {
      foundLast=true;
    }
    i++;
  }
  return vals;
}

Fixed version (ground truth):
/** 
 * Get repeated values from a form.  If "foo" is passed in, values in the form of parameters "foo_0", "foo_1", etc. are returned.
 * @param request   the HTTP request containing the form information
 * @param param     the repeated parameter
 * @return a List of Strings
 */
private List getRepeatedParameter(HttpServletRequest request,String param){
  List vals=new LinkedList();
  int i=0;
  boolean foundLast=false;
  while (!foundLast) {
    String s=request.getParameter(param + "String_Node_Str" + i);
    if (s != null) {
      vals.add(s.trim());
    }
 else {
      foundLast=true;
    }
    i++;
  }
  return vals;
}
Program: 52605
Project: 52605
Buggy source:
/** 
 * Get all the items in this collection.  The order is indeterminate.
 * @return  an iterator over the items in the collection.
 */
public ItemIterator getItems() throws SQLException {
  TableRowIterator rows=DatabaseManager.query(ourContext,"String_Node_Str","String_Node_Str" + "String_Node_Str" + getID() + "String_Node_Str");
  return new ItemIterator(ourContext,rows);
}

Fixed version (ground truth):
/** 
 * Get all the items in this collection.  The order is indeterminate.
 * @return  an iterator over the items in the collection.
 */
public ItemIterator getItems() throws SQLException {
  TableRowIterator rows=DatabaseManager.query(ourContext,"String_Node_Str","String_Node_Str" + "String_Node_Str" + "String_Node_Str" + getID() + "String_Node_Str");
  return new ItemIterator(ourContext,rows);
}
Program: 52610
Project: 52610
Buggy source:
/** 
 * Get repeated values from a form.  If "foo" is passed in, values in the form of parameters "foo_0", "foo_1", etc. are returned.
 * @param request   the HTTP request containing the form information
 * @param param     the repeated parameter
 * @return a List of Strings
 */
private List getRepeatedParameter(HttpServletRequest request,String param){
  List vals=new LinkedList();
  int i=0;
  boolean foundLast=false;
  while (!foundLast) {
    String s=request.getParameter(param + "String_Node_Str" + i);
    if (s != null && !s.equals("String_Node_Str")) {
      vals.add(s);
    }
    foundLast=(s == null);
    i++;
  }
  return vals;
}

Fixed version (ground truth):
/** 
 * Get repeated values from a form.  If "foo" is passed in, values in the form of parameters "foo_0", "foo_1", etc. are returned.
 * @param request   the HTTP request containing the form information
 * @param param     the repeated parameter
 * @return a List of Strings
 */
private List getRepeatedParameter(HttpServletRequest request,String param){
  List vals=new LinkedList();
  int i=0;
  boolean foundLast=false;
  while (!foundLast) {
    String s=request.getParameter(param + "String_Node_Str" + i);
    if (s != null) {
      vals.add(s);
    }
 else {
      foundLast=true;
    }
    i++;
  }
  return vals;
}
Program: 52612
Project: 52612
Buggy source:
/** 
 * Return the request that the system should be dealing with, given the request that the browse just sent.  If the incoming request is from a redirect resulting from successful authentication, a request object corresponding to the original request that prompted authentication is returned.  Otherwise, the request passed in is returned.
 * @param request   the incoming HTTP request
 * @return   the HTTP request the DSpace system should deal with
 */
public static HttpServletRequest getRealRequest(HttpServletRequest request){
  HttpSession session=request.getSession();
  if (session.getAttribute("String_Node_Str") != null) {
    log.info("String_Node_Str");
    RequestInfo requestInfo=(RequestInfo)session.getAttribute("String_Node_Str");
    HttpServletRequest actualRequest=requestInfo.wrapRequest(request);
    session.removeAttribute("String_Node_Str");
    session.removeAttribute("String_Node_Str");
    session.removeAttribute("String_Node_Str");
    return actualRequest;
  }
 else {
    return request;
  }
}

Fixed version (ground truth):
/** 
 * Return the request that the system should be dealing with, given the request that the browse just sent.  If the incoming request is from a redirect resulting from successful authentication, a request object corresponding to the original request that prompted authentication is returned.  Otherwise, the request passed in is returned.
 * @param request   the incoming HTTP request
 * @return   the HTTP request the DSpace system should deal with
 */
public static HttpServletRequest getRealRequest(HttpServletRequest request){
  HttpSession session=request.getSession();
  if (session.getAttribute("String_Node_Str") != null) {
    RequestInfo requestInfo=(RequestInfo)session.getAttribute("String_Node_Str");
    HttpServletRequest actualRequest;
    if (requestInfo == null) {
      actualRequest=request;
    }
 else {
      actualRequest=requestInfo.wrapRequest(request);
    }
    session.removeAttribute("String_Node_Str");
    session.removeAttribute("String_Node_Str");
    session.removeAttribute("String_Node_Str");
    return actualRequest;
  }
 else {
    return request;
  }
}
Program: 52613
Project: 52613
Buggy source:
/** 
 * Update the ResourcePolicy
 */
public void update() throws SQLException, AuthorizeException {
  DatabaseManager.update(myContext,myRow);
}

Fixed version (ground truth):
/** 
 * Update the ResourcePolicy
 */
public void update() throws SQLException {
  DatabaseManager.update(myContext,myRow);
}
Program: 52614
Project: 52614
Buggy source:
/** 
 * Process information from "enter new password"
 * @param context   current DSpace context
 * @param request   current servlet request object
 * @param response  current servlet response object
 */
private void processNewPassword(Context context,HttpServletRequest request,HttpServletResponse response) throws ServletException, IOException, SQLException, AuthorizeException {
  String key=request.getParameter("String_Node_Str");
  EPerson eperson=AccountManager.getEPerson(context,key);
  if (eperson == null) {
    log.info(LogManager.getHeader(context,"String_Node_Str","String_Node_Str" + key));
    JSPManager.showJSP(request,response,"String_Node_Str");
    return;
  }
  boolean passwordOK=EditProfileServlet.confirmAndSetPassword(eperson,request);
  if (passwordOK) {
    log.info(LogManager.getHeader(context,"String_Node_Str","String_Node_Str" + eperson.getEmail()));
    AccountManager.deleteToken(context,key);
    JSPManager.showJSP(request,response,"String_Node_Str");
    context.complete();
  }
 else {
    request.setAttribute("String_Node_Str",new Boolean(true));
    request.setAttribute("String_Node_Str",key);
    JSPManager.showJSP(request,response,"String_Node_Str");
  }
}

Fixed version (ground truth):
/** 
 * Process information from "enter new password"
 * @param context   current DSpace context
 * @param request   current servlet request object
 * @param response  current servlet response object
 */
private void processNewPassword(Context context,HttpServletRequest request,HttpServletResponse response) throws ServletException, IOException, SQLException, AuthorizeException {
  String key=request.getParameter("String_Node_Str");
  EPerson eperson=AccountManager.getEPerson(context,key);
  if (eperson == null) {
    log.info(LogManager.getHeader(context,"String_Node_Str","String_Node_Str" + key));
    JSPManager.showJSP(request,response,"String_Node_Str");
    return;
  }
  boolean passwordOK=EditProfileServlet.confirmAndSetPassword(eperson,request);
  if (passwordOK) {
    log.info(LogManager.getHeader(context,"String_Node_Str","String_Node_Str" + eperson.getEmail()));
    AccountManager.deleteToken(context,key);
    JSPManager.showJSP(request,response,"String_Node_Str");
    context.complete();
  }
 else {
    request.setAttribute("String_Node_Str",new Boolean(true));
    request.setAttribute("String_Node_Str",key);
    request.setAttribute("String_Node_Str",eperson);
    JSPManager.showJSP(request,response,"String_Node_Str");
  }
}
Program: 52616
Project: 52616
Buggy source:
private static void doState(Context c,WorkflowItem wi,int newstate,EPerson newowner) throws SQLException, IOException, AuthorizeException {
  Collection mycollection=wi.getCollection();
  Group mygroup=null;
  wi.setState(newstate);
switch (newstate) {
case WFSTATE_REVIEWPOOL:
    wi.setOwner(null);
  mygroup=mycollection.getWorkflowGroup(1);
if (mygroup != null) {
  createTasks(c,wi,mygroup);
  wi.update();
  notifyGroupOfTask(c,mygroup,wi);
}
 else {
  doState(c,wi,WFSTATE_ADMINPOOL,null);
}
break;
case WFSTATE_REVIEW:
deleteTasks(c,wi);
wi.setOwner(newowner);
break;
case WFSTATE_ADMINPOOL:
wi.setOwner(null);
mygroup=mycollection.getWorkflowGroup(2);
if (mygroup != null) {
createTasks(c,wi,mygroup);
notifyGroupOfTask(c,mygroup,wi);
}
 else {
doState(c,wi,WFSTATE_EDITPOOL,null);
}
break;
case WFSTATE_ADMIN:
deleteTasks(c,wi);
wi.setOwner(newowner);
break;
case WFSTATE_EDITPOOL:
wi.setOwner(null);
mygroup=mycollection.getWorkflowGroup(3);
if (mygroup != null) {
createTasks(c,wi,mygroup);
notifyGroupOfTask(c,mygroup,wi);
}
 else {
doState(c,wi,WFSTATE_ARCHIVE,newowner);
}
break;
case WFSTATE_EDIT:
deleteTasks(c,wi);
wi.setOwner(newowner);
break;
case WFSTATE_ARCHIVE:
try {
deleteTasks(c,wi);
mycollection=wi.getCollection();
Item myitem=archive(c,wi);
notifyOfArchive(c,myitem,mycollection);
DSIndexer.indexItem(c,myitem);
}
 catch (IOException e) {
throw e;
}
catch (SQLException e) {
throw e;
}
break;
}
if (wi != null) wi.update();
}

Fixed version (ground truth):
private static void doState(Context c,WorkflowItem wi,int newstate,EPerson newowner) throws SQLException, IOException, AuthorizeException {
  Collection mycollection=wi.getCollection();
  Group mygroup=null;
  wi.setState(newstate);
switch (newstate) {
case WFSTATE_REVIEWPOOL:
    wi.setOwner(null);
  mygroup=mycollection.getWorkflowGroup(1);
if (mygroup != null) {
  createTasks(c,wi,mygroup);
  wi.update();
  notifyGroupOfTask(c,mygroup,wi);
}
 else {
  doState(c,wi,WFSTATE_ADMINPOOL,null);
}
break;
case WFSTATE_REVIEW:
deleteTasks(c,wi);
wi.setOwner(newowner);
break;
case WFSTATE_ADMINPOOL:
wi.setOwner(null);
mygroup=mycollection.getWorkflowGroup(2);
if (mygroup != null) {
createTasks(c,wi,mygroup);
notifyGroupOfTask(c,mygroup,wi);
}
 else {
doState(c,wi,WFSTATE_EDITPOOL,null);
}
break;
case WFSTATE_ADMIN:
deleteTasks(c,wi);
wi.setOwner(newowner);
break;
case WFSTATE_EDITPOOL:
wi.setOwner(null);
mygroup=mycollection.getWorkflowGroup(3);
if (mygroup != null) {
createTasks(c,wi,mygroup);
notifyGroupOfTask(c,mygroup,wi);
}
 else {
doState(c,wi,WFSTATE_ARCHIVE,newowner);
}
break;
case WFSTATE_EDIT:
deleteTasks(c,wi);
wi.setOwner(newowner);
break;
case WFSTATE_ARCHIVE:
try {
deleteTasks(c,wi);
mycollection=wi.getCollection();
Item myitem=archive(c,wi);
notifyOfArchive(c,myitem,mycollection);
}
 catch (IOException e) {
throw e;
}
catch (SQLException e) {
throw e;
}
break;
}
if (wi != null) wi.update();
}
Program: 52617
Project: 52617
Buggy source:
/** 
 * Set the e-person that originally submitted this item.  This is a public method since it is handled by the WorkspaceItem class in the ingest package. <code>update</code> must be called to write the change to the database.
 * @param sub  the submitter
 */
public void setSubmitter(EPerson sub){
  submitter=sub;
}

Fixed version (ground truth):
/** 
 * Set the e-person that originally submitted this item.  This is a public method since it is handled by the WorkspaceItem class in the ingest package. <code>update</code> must be called to write the change to the database.
 * @param sub  the submitter
 */
public void setSubmitter(EPerson sub){
  submitter=sub;
  if (submitter != null) {
    itemRow.setColumn("String_Node_Str",submitter.getID());
  }
 else {
    itemRow.setColumnNull("String_Node_Str");
  }
}
Program: 52618
Project: 52618
Buggy source:
protected void doPost(HttpServletRequest request,HttpServletResponse response) throws ServletException, IOException {
  processRequest(request,response,true);
}

Fixed version (ground truth):
protected void doPost(HttpServletRequest request,HttpServletResponse response) throws ServletException, IOException {
  processRequest(request,response);
}
Program: 52619
Project: 52619
Buggy source:
protected void doGet(HttpServletRequest request,HttpServletResponse response) throws ServletException, IOException {
  processRequest(request,response,false);
}

Fixed version (ground truth):
protected void doGet(HttpServletRequest request,HttpServletResponse response) throws ServletException, IOException {
  processRequest(request,response);
}
Program: 52620
Project: 52620
Buggy source:
/** 
 * Process an incoming request
 * @param request    the request object
 * @param response   the response object
 * @param isPost     if true, this is a POST
 */
private void processRequest(HttpServletRequest request,HttpServletResponse response,boolean isPost) throws ServletException, IOException {
  Context context=null;
  UIUtil.storeOriginalURL(request);
  try {
    context=UIUtil.obtainContext(request);
    request=Authenticate.getRealRequest(request);
    if (isPost) {
      doDSPost(context,request,response);
    }
 else {
      doDSGet(context,request,response);
    }
  }
 catch (  SQLException se) {
    log.warn(LogManager.getHeader(context,"String_Node_Str",se.toString()),se);
    UIUtil.sendAlert(request,se);
    JSPManager.showInternalError(request,response);
  }
catch (  AuthorizeException ae) {
    if (context.getCurrentUser() == null) {
      Authenticate.startAuthentication(context,request,response);
    }
 else {
      log.info(LogManager.getHeader(context,"String_Node_Str",ae.toString()));
      JSPManager.showAuthorizeError(request,response,ae);
    }
  }
  if (context != null && context.isValid()) {
    context.abort();
  }
}

Fixed version (ground truth):
/** 
 * Process an incoming request
 * @param request    the request object
 * @param response   the response object
 */
private void processRequest(HttpServletRequest request,HttpServletResponse response) throws ServletException, IOException {
  Context context=null;
  UIUtil.storeOriginalURL(request);
  try {
    context=UIUtil.obtainContext(request);
    request=Authenticate.getRealRequest(request);
    if (log.isDebugEnabled()) {
      log.debug(LogManager.getHeader(context,"String_Node_Str",UIUtil.getRequestLogInfo(request)));
    }
    if (request.getMethod().equals("String_Node_Str")) {
      doDSPost(context,request,response);
    }
 else {
      doDSGet(context,request,response);
    }
  }
 catch (  SQLException se) {
    log.warn(LogManager.getHeader(context,"String_Node_Str",se.toString()),se);
    UIUtil.sendAlert(request,se);
    JSPManager.showInternalError(request,response);
  }
catch (  AuthorizeException ae) {
    if (context.getCurrentUser() == null) {
      Authenticate.startAuthentication(context,request,response);
    }
 else {
      log.info(LogManager.getHeader(context,"String_Node_Str",ae.toString()));
      JSPManager.showAuthorizeError(request,response,ae);
    }
  }
  if (context != null && context.isValid()) {
    context.abort();
  }
}
Program: 52621
Project: 52621
Buggy source:
protected void doDSGet(Context context,HttpServletRequest request,HttpServletResponse response) throws ServletException, IOException, SQLException, AuthorizeException {
  X509Certificate[] certs=(X509Certificate[])request.getAttribute("String_Node_Str");
  if (certs.length == 0) {
    if (request.getParameter("String_Node_Str") != null) {
      log.info(LogManager.getHeader(context,"String_Node_Str","String_Node_Str"));
      JSPManager.showJSP(request,response,"String_Node_Str");
    }
 else {
      JSPManager.showJSP(request,response,"String_Node_Str");
    }
  }
 else {
    try {
      if (X509Manager.isValid(certs[0])) {
        EPerson eperson=X509Manager.getUser(context,certs[0]);
        if (eperson != null && eperson.getActive()) {
          Authenticate.loggedIn(context,request,eperson);
          log.info(LogManager.getHeader(context,"String_Node_Str","String_Node_Str"));
          Authenticate.resumeInterruptedRequest(request,response);
          return;
        }
 else {
          log.info(LogManager.getHeader(context,"String_Node_Str","String_Node_Str"));
          JSPManager.showJSP(request,response,"String_Node_Str");
        }
      }
 else {
        log.info(LogManager.getHeader(context,"String_Node_Str","String_Node_Str"));
        JSPManager.showJSP(request,response,"String_Node_Str");
      }
    }
 catch (    CertificateException ce) {
      log.warn(LogManager.getHeader(context,"String_Node_Str","String_Node_Str"),ce);
      JSPManager.showInternalError(request,response);
    }
  }
}

Fixed version (ground truth):
protected void doDSGet(Context context,HttpServletRequest request,HttpServletResponse response) throws ServletException, IOException, SQLException, AuthorizeException {
  X509Certificate[] certs=(X509Certificate[])request.getAttribute("String_Node_Str");
  if (certs == null || certs.length == 0) {
    if (request.getParameter("String_Node_Str") != null) {
      log.info(LogManager.getHeader(context,"String_Node_Str","String_Node_Str"));
      JSPManager.showJSP(request,response,"String_Node_Str");
    }
 else {
      JSPManager.showJSP(request,response,"String_Node_Str");
    }
  }
 else {
    try {
      if (X509Manager.isValid(certs[0])) {
        EPerson eperson=X509Manager.getUser(context,certs[0]);
        if (eperson != null && eperson.getActive()) {
          Authenticate.loggedIn(context,request,eperson);
          log.info(LogManager.getHeader(context,"String_Node_Str","String_Node_Str"));
          Authenticate.resumeInterruptedRequest(request,response);
          return;
        }
 else {
          log.info(LogManager.getHeader(context,"String_Node_Str","String_Node_Str"));
          JSPManager.showJSP(request,response,"String_Node_Str");
        }
      }
 else {
        log.info(LogManager.getHeader(context,"String_Node_Str","String_Node_Str"));
        JSPManager.showJSP(request,response,"String_Node_Str");
      }
    }
 catch (    CertificateException ce) {
      log.warn(LogManager.getHeader(context,"String_Node_Str","String_Node_Str"),ce);
      JSPManager.showInternalError(request,response);
    }
  }
}