Program: 34758
Project: 34758
Buggy source:
/** 
 * Method to return log event data in json format. If the collector version passed is greater than 1.0 then the jsonifyEvent call is passed to another version of CollectorJsonUtils.
 * @param event The object originating from logging source which contains necessary fields
 * @param eventType The type of event
 * @param servername The name of the server
 * @param wlpUserDir The name of wlp user directory
 * @param serverHostName The name of server host
 * @param collectorVersion The version number
 * @param tags An array of tags
 * @param maxFieldLength The max character length of strings
 */
public static String jsonifyEvent(Object event,String eventType,String serverName,String wlpUserDir,String serverHostName,String collectorVersion,String[] tags,int maxFieldLength){
  if (!collectorVersion.equals("String_Node_Str")) {
    return CollectorJsonUtils1_1.jsonifyEvent(event,eventType,serverName,wlpUserDir,serverHostName,tags,maxFieldLength);
  }
 else {
    if (eventType.equals(CollectorConstants.GC_EVENT_TYPE)) {
      return jsonifyGCEvent(serverHostName,wlpUserDir,serverName,(HCGCData)event,tags);
    }
 else     if (eventType.equals(CollectorConstants.MESSAGES_LOG_EVENT_TYPE)) {
      return jsonifyTraceAndMessage(maxFieldLength,wlpUserDir,serverName,serverHostName,CollectorConstants.MESSAGES_LOG_EVENT_TYPE,event,tags);
    }
 else     if (eventType.equals(CollectorConstants.TRACE_LOG_EVENT_TYPE)) {
      return jsonifyTraceAndMessage(maxFieldLength,wlpUserDir,serverName,serverHostName,CollectorConstants.TRACE_LOG_EVENT_TYPE,event,tags);
    }
 else     if (eventType.equals(CollectorConstants.FFDC_EVENT_TYPE)) {
      return jsonifyFFDC(maxFieldLength,wlpUserDir,serverName,serverHostName,CollectorConstants.FFDC_EVENT_TYPE,event,tags);
    }
 else     if (eventType.equals(CollectorConstants.ACCESS_LOG_EVENT_TYPE)) {
      return jsonifyAccess(-1,wlpUserDir,serverName,serverHostName,CollectorConstants.ACCESS_LOG_EVENT_TYPE,event,tags);
    }
  }
  return "String_Node_Str";
}

Fixed version (ground truth):
/** 
 * Method to return log event data in json format. If the collector version passed is greater than 1.0 then the jsonifyEvent call is passed to another version of CollectorJsonUtils.
 * @param event The object originating from logging source which contains necessary fields
 * @param eventType The type of event
 * @param servername The name of the server
 * @param wlpUserDir The name of wlp user directory
 * @param serverHostName The name of server host
 * @param collectorVersion The version number
 * @param tags An array of tags
 * @param maxFieldLength The max character length of strings
 */
public static String jsonifyEvent(Object event,String eventType,String serverName,String wlpUserDir,String serverHostName,String collectorVersion,String[] tags,int maxFieldLength){
  if (!collectorVersion.equals("String_Node_Str")) {
    return CollectorJsonUtils1_1.jsonifyEvent(event,eventType,serverName,wlpUserDir,serverHostName,tags,maxFieldLength);
  }
 else {
    if (eventType.equals(CollectorConstants.GC_EVENT_TYPE)) {
      if (event instanceof GenericData) {
        return jsonifyGCEvent(-1,wlpUserDir,serverName,serverHostName,CollectorConstants.GC_EVENT_TYPE,event,tags);
      }
 else {
        return jsonifyGCEvent(serverHostName,wlpUserDir,serverName,(HCGCData)event,tags);
      }
    }
 else     if (eventType.equals(CollectorConstants.MESSAGES_LOG_EVENT_TYPE)) {
      return jsonifyTraceAndMessage(maxFieldLength,wlpUserDir,serverName,serverHostName,CollectorConstants.MESSAGES_LOG_EVENT_TYPE,event,tags);
    }
 else     if (eventType.equals(CollectorConstants.TRACE_LOG_EVENT_TYPE)) {
      return jsonifyTraceAndMessage(maxFieldLength,wlpUserDir,serverName,serverHostName,CollectorConstants.TRACE_LOG_EVENT_TYPE,event,tags);
    }
 else     if (eventType.equals(CollectorConstants.FFDC_EVENT_TYPE)) {
      return jsonifyFFDC(maxFieldLength,wlpUserDir,serverName,serverHostName,CollectorConstants.FFDC_EVENT_TYPE,event,tags);
    }
 else     if (eventType.equals(CollectorConstants.ACCESS_LOG_EVENT_TYPE)) {
      return jsonifyAccess(-1,wlpUserDir,serverName,serverHostName,CollectorConstants.ACCESS_LOG_EVENT_TYPE,event,tags);
    }
  }
  return "String_Node_Str";
}