Program: 167394
Project: 167394
Buggy source:
protected void handleUsingPullParser(Message inputMessage,ISendMessageCallback callback,boolean unitOfWorkBoundaryReached){
  try {
    Map<String,String> currentDataAtLevel=new HashMap<>();
    XmlPullParser parser=XmlPullParserFactory.newInstance().newPullParser();
    ArrayList<String> inputRows=((TextMessage)inputMessage).getPayload();
    ArrayList<EntityData> payload=new ArrayList<EntityData>();
    if (inputRows != null) {
      for (      String xml : inputRows) {
        List<StringBuilder> paths=new ArrayList<>();
        parser.setInput(new StringReader(xml));
        int eventType=parser.getEventType();
        while (eventType != XmlPullParser.END_DOCUMENT) {
switch (eventType) {
case XmlPullParser.START_TAG:
            for (            StringBuilder path : paths) {
              path.append("String_Node_Str").append(parser.getName());
            }
          StringBuilder shortPath=new StringBuilder("String_Node_Str").append(parser.getName());
        paths.add(shortPath);
      addAttributes(parser,paths,currentDataAtLevel);
    break;
case XmlPullParser.END_TAG:
  EntityData data=processCurrentLevel(paths.get(0).toString(),currentDataAtLevel);
if (data != null) {
  payload.add(data);
  getComponentStatistics().incrementNumberEntitiesProcessed(threadNumber);
}
String removed=paths.remove(paths.size() - 1).toString();
Iterator<Entry<String,String>> entries=currentDataAtLevel.entrySet().iterator();
while (entries.hasNext()) {
Entry<String,String> entry=entries.next();
if (entry.getKey().startsWith(removed)) {
entries.remove();
}
}
for (StringBuilder path : paths) {
int index=path.lastIndexOf("String_Node_Str");
if (index >= 0) {
path.replace(index,path.length(),"String_Node_Str");
}
}
break;
case XmlPullParser.TEXT:
String text=parser.getText();
for (StringBuilder path : paths) {
currentDataAtLevel.put(String.format("String_Node_Str",path),text);
currentDataAtLevel.put(path.toString(),text);
}
break;
}
if (payload.size() > rowsPerMessage) {
callback.sendEntityDataMessage(null,payload);
payload=new ArrayList<>();
}
eventType=parser.next();
}
}
if (payload.size() > 0) {
callback.sendEntityDataMessage(null,payload);
payload=new ArrayList<>();
}
}
}
 catch (RuntimeException ex) {
throw ex;
}
catch (Exception e) {
throw new RuntimeException(e);
}
}

Fixed version (ground truth):
protected void handleUsingPullParser(Message inputMessage,ISendMessageCallback callback,boolean unitOfWorkBoundaryReached){
  try {
    Map<String,String> currentDataAtLevel=new HashMap<>();
    XmlPullParser parser=XmlPullParserFactory.newInstance().newPullParser();
    ArrayList<String> inputRows=((TextMessage)inputMessage).getPayload();
    ArrayList<EntityData> payload=new ArrayList<EntityData>();
    if (inputRows != null) {
      for (      String xml : inputRows) {
        List<StringBuilder> paths=new ArrayList<>();
        parser.setInput(new StringReader(xml));
        int eventType=parser.getEventType();
        while (eventType != XmlPullParser.END_DOCUMENT) {
switch (eventType) {
case XmlPullParser.START_TAG:
            for (            StringBuilder path : paths) {
              path.append("String_Node_Str").append(parser.getName());
            }
          StringBuilder shortPath=new StringBuilder("String_Node_Str").append(parser.getName());
        paths.add(shortPath);
      addAttributes(parser,paths,currentDataAtLevel);
    break;
case XmlPullParser.END_TAG:
  List<EntityData> data=processCurrentLevel(paths.get(0).toString(),currentDataAtLevel);
if (data != null) {
  payload.addAll(data);
  getComponentStatistics().incrementNumberEntitiesProcessed(threadNumber);
}
String removed=paths.remove(paths.size() - 1).toString();
Iterator<Entry<String,String>> entries=currentDataAtLevel.entrySet().iterator();
while (entries.hasNext()) {
Entry<String,String> entry=entries.next();
if (entry.getKey().startsWith(removed)) {
entries.remove();
}
}
for (StringBuilder path : paths) {
int index=path.lastIndexOf("String_Node_Str");
if (index >= 0) {
path.replace(index,path.length(),"String_Node_Str");
}
}
break;
case XmlPullParser.TEXT:
String text=parser.getText();
for (StringBuilder path : paths) {
currentDataAtLevel.put(String.format("String_Node_Str",path),text);
currentDataAtLevel.put(path.toString(),text);
}
break;
}
if (payload.size() > rowsPerMessage) {
callback.sendEntityDataMessage(null,payload);
payload=new ArrayList<>();
}
eventType=parser.next();
}
}
if (payload.size() > 0) {
callback.sendEntityDataMessage(null,payload);
payload=new ArrayList<>();
}
}
}
 catch (RuntimeException ex) {
throw ex;
}
catch (Exception e) {
throw new RuntimeException(e);
}
}