Program: 52313
Project: 52313
Buggy source:
/** 
 * Wraps the given HttpServletRequest, using the given MultivaluedMap to provide all request parameters. All HttpServletRequest functions which do not deal with parameter names and values are delegated to the wrapped request.
 * @param request The HttpServletRequest to wrap.
 * @param parameters All request parameters.
 */
public APIRequest(HttpServletRequest request,MultivaluedMap<String,String> parameters){
  super(request);
  if (request.getHeader("String_Node_Str") != null && !request.getHeader("String_Node_Str").isEmpty()) {
    this.remoteHost=request.getHeader("String_Node_Str");
  }
 else   if (request.getHeader("String_Node_Str") != null && !request.getHeader("String_Node_Str").isEmpty()) {
    this.remoteHost=request.getHeader("String_Node_Str");
  }
 else   if (request.getRemoteHost() != null && !request.getRemoteHost().isEmpty()) {
    this.remoteHost=request.getRemoteHost();
  }
 else {
    this.remoteHost=null;
  }
  if (request.getHeader("String_Node_Str") != null && !request.getHeader("String_Node_Str").isEmpty()) {
    this.remoteAddr=request.getHeader("String_Node_Str");
  }
 else   if (request.getHeader("String_Node_Str") != null && !request.getHeader("String_Node_Str").isEmpty()) {
    this.remoteAddr=request.getHeader("String_Node_Str");
  }
 else   if (request.getRemoteHost() != null && !request.getRemoteAddr().isEmpty()) {
    this.remoteAddr=request.getRemoteAddr();
  }
 else {
    this.remoteAddr=null;
  }
  this.parameters=new HashMap<String,String[]>(parameters.size());
  for (  Map.Entry<String,List<String>> entry : parameters.entrySet()) {
    String name=entry.getKey();
    List<String> values=entry.getValue();
    this.parameters.put(name,values.toArray(new String[values.size()]));
  }
}

Fixed version (ground truth):
/** 
 * Wraps the given HttpServletRequest, using the given MultivaluedMap to provide all request parameters. All HttpServletRequest functions which do not deal with parameter names and values are delegated to the wrapped request.
 * @param request The HttpServletRequest to wrap.
 * @param parameters All request parameters.
 */
public APIRequest(HttpServletRequest request,MultivaluedMap<String,String> parameters){
  super(request);
  if (request.getHeader("String_Node_Str") != null && !request.getHeader("String_Node_Str").isEmpty())   this.remoteHost=request.getHeader("String_Node_Str");
 else   if (request.getHeader("String_Node_Str") != null && !request.getHeader("String_Node_Str").isEmpty())   this.remoteHost=request.getHeader("String_Node_Str");
 else   if (request.getRemoteHost() != null && !request.getRemoteHost().isEmpty())   this.remoteHost=request.getRemoteHost();
 else   this.remoteHost=null;
  if (request.getHeader("String_Node_Str") != null && !request.getHeader("String_Node_Str").isEmpty())   this.remoteAddr=request.getHeader("String_Node_Str");
 else   if (request.getHeader("String_Node_Str") != null && !request.getHeader("String_Node_Str").isEmpty())   this.remoteAddr=request.getHeader("String_Node_Str");
 else   if (request.getRemoteHost() != null && !request.getRemoteAddr().isEmpty())   this.remoteAddr=request.getRemoteAddr();
 else   this.remoteAddr=null;
  this.parameters=new HashMap<String,String[]>(parameters.size());
  for (  Map.Entry<String,List<String>> entry : parameters.entrySet()) {
    String name=entry.getKey();
    List<String> values=entry.getValue();
    this.parameters.put(name,values.toArray(new String[values.size()]));
  }
}