Program: 160582
Project: 160582
Buggy source:
@SuppressWarnings("String_Node_Str") public void cleanupUnmodified(){
  Iterator<Long> iterator=resultModel.keySet().iterator();
  while (iterator.hasNext()) {
    Long oid=iterator.next();
    IdEObject idEObject=resultModel.get(oid);
    IdEObject originalObject=(IdEObject)oldModel.get(oid);
    if (originalObject != null) {
      boolean objectChanged=false;
      for (      EAttribute eAttribute : idEObject.eClass().getEAllAttributes()) {
        Object value=idEObject.eGet(eAttribute);
        Object originalValue=originalObject.eGet(eAttribute);
        if (((value == null && originalValue != null) || (value != null && originalValue == null))) {
          objectChanged=true;
          continue;
        }
        if (!(value == null && originalValue == null) && !value.equals(originalValue)) {
          objectChanged=true;
          continue;
        }
      }
      if (!objectChanged) {
        for (        EReference eReference : idEObject.eClass().getEAllReferences()) {
          if (eReference.isMany()) {
            List list=(List)idEObject.eGet(eReference);
            List originalList=(List)originalObject.eGet(eReference);
            if (list.size() != originalList.size()) {
              objectChanged=true;
              continue;
            }
            for (int i=0; i < list.size(); i++) {
              IdEObject referencedObject=(IdEObject)list.get(i);
              IdEObject originalReferencedObject=(IdEObject)originalList.get(i);
              if ((referencedObject == null && originalReferencedObject != null) || (referencedObject != null && originalReferencedObject == null)) {
                objectChanged=true;
                continue;
              }
              if (!(referencedObject == null && originalReferencedObject == null) && referencedObject.getOid() != originalReferencedObject.getOid()) {
                objectChanged=true;
                continue;
              }
            }
          }
 else {
            IdEObject referencedObject=(IdEObject)idEObject.eGet(eReference);
            IdEObject originalReferencedObject=(IdEObject)originalObject.eGet(eReference);
            if ((referencedObject == null && originalReferencedObject != null) || (referencedObject != null && originalReferencedObject == null)) {
              objectChanged=true;
              continue;
            }
            if (!(referencedObject == null && originalReferencedObject == null) && referencedObject.getOid() != originalReferencedObject.getOid()) {
              objectChanged=true;
              continue;
            }
          }
        }
      }
      if (!objectChanged) {
        iterator.remove();
      }
    }
  }
}

Fixed version (ground truth):
@SuppressWarnings("String_Node_Str") public void cleanupUnmodified(){
  Iterator<Long> iterator=resultModel.keySet().iterator();
  while (iterator.hasNext()) {
    Long oid=iterator.next();
    IdEObject idEObject=resultModel.get(oid);
    IdEObject originalObject=oldModel.get(oid);
    if (originalObject != null) {
      boolean objectChanged=false;
      for (      EAttribute eAttribute : idEObject.eClass().getEAllAttributes()) {
        Object value=idEObject.eGet(eAttribute);
        Object originalValue=originalObject.eGet(eAttribute);
        if (((value == null && originalValue != null) || (value != null && originalValue == null))) {
          objectChanged=true;
          continue;
        }
        if (!(value == null && originalValue == null) && !value.equals(originalValue)) {
          objectChanged=true;
          continue;
        }
      }
      if (!objectChanged) {
        for (        EReference eReference : idEObject.eClass().getEAllReferences()) {
          if (eReference.isMany()) {
            List list=(List)idEObject.eGet(eReference);
            List originalList=(List)originalObject.eGet(eReference);
            if (list.size() != originalList.size()) {
              objectChanged=true;
              continue;
            }
            for (int i=0; i < list.size(); i++) {
              IdEObject referencedObject=(IdEObject)list.get(i);
              IdEObject originalReferencedObject=(IdEObject)originalList.get(i);
              if ((referencedObject == null && originalReferencedObject != null) || (referencedObject != null && originalReferencedObject == null)) {
                objectChanged=true;
                continue;
              }
              if (!(referencedObject == null && originalReferencedObject == null) && referencedObject.getOid() != originalReferencedObject.getOid()) {
                objectChanged=true;
                continue;
              }
            }
          }
 else {
            IdEObject referencedObject=(IdEObject)idEObject.eGet(eReference);
            IdEObject originalReferencedObject=(IdEObject)originalObject.eGet(eReference);
            if ((referencedObject == null && originalReferencedObject != null) || (referencedObject != null && originalReferencedObject == null)) {
              objectChanged=true;
              continue;
            }
            if (!(referencedObject == null && originalReferencedObject == null) && referencedObject.getOid() != originalReferencedObject.getOid()) {
              objectChanged=true;
              continue;
            }
          }
        }
      }
      if (!objectChanged) {
        iterator.remove();
      }
    }
  }
}