Program: 138768
Project: 138768
Buggy source:
private void tansferFile(File parentFolder) throws Exception {
  if (!parentFolder.exists()) {
    return;
  }
  List<File> fileList=new ArrayList<File>();
  FilesUtils.getAllFilesFromFolder(parentFolder,fileList,nonPropertyFileFilter);
  for (  File propFile : fileList) {
    URI uri=URI.createFileURI(propFile.getAbsolutePath());
    Resource resource=resourceSet.getResource(uri,true);
    Property property=(Property)EcoreUtil.getObjectByType(resource.getContents(),PropertiesPackage.eINSTANCE.getProperty());
    if (property != null) {
      Item item=property.getItem();
      String connNameBofore=null;
      String connNameAfter=null;
      if (item instanceof ConnectionItem) {
        Connection conn=((ConnectionItem)item).getConnection();
        connNameBofore=conn.eResource().getURI().trimFileExtension().lastSegment();
        String fileName=propFile.getName();
        int lastIndex=fileName.lastIndexOf("String_Node_Str");
        if (lastIndex > 0) {
          fileName=fileName.substring(0,lastIndex);
        }
 else {
          fileName=new Path(fileName).removeFileExtension().lastSegment();
        }
        property.setLabel(fileName);
      }
      IPath path=new Path(item.getState().getPath());
      if (ProxyRepositoryFactory.getInstance().getFolderItem(ProjectManager.getInstance().getCurrentProject(),ERepositoryObjectType.getItemType(item),path) == null) {
        ProxyRepositoryFactory.getInstance().createFolder(ERepositoryObjectType.getItemType(item),path.removeLastSegments(1),path.lastSegment());
      }
      ProxyRepositoryFactory.getInstance().create(item,path,true);
      if (item instanceof ConnectionItem) {
        Connection conn=((ConnectionItem)item).getConnection();
        if (conn.eIsProxy()) {
          conn=(Connection)EObjectHelper.resolveObject(conn);
        }
        connNameAfter=conn.eResource().getURI().trimFileExtension().lastSegment();
        if (connNameBofore != null && connNameAfter != null) {
          getReplaceStringMap().put(connNameBofore,connNameAfter);
        }
      }
    }
  }
}

Fixed version (ground truth):
private void tansferFile(File parentFolder) throws Exception {
  if (!parentFolder.exists()) {
    return;
  }
  List<File> fileList=new ArrayList<File>();
  FilesUtils.getAllFilesFromFolder(parentFolder,fileList,nonPropertyFileFilter);
  for (  File propFile : fileList) {
    URI uri=URI.createFileURI(propFile.getAbsolutePath());
    Resource resource=resourceSet.getResource(uri,true);
    Property property=(Property)EcoreUtil.getObjectByType(resource.getContents(),PropertiesPackage.eINSTANCE.getProperty());
    if (property != null) {
      Item item=property.getItem();
      String connNameBofore=null;
      String connNameAfter=null;
      if (item instanceof ConnectionItem) {
        Connection conn=((ConnectionItem)item).getConnection();
        connNameBofore=conn.eResource().getURI().trimFileExtension().lastSegment();
        String version=property.getVersion();
        if (version == null) {
          version="String_Node_Str";
        }
        String label=conn.getName() + "String_Node_Str" + version;
        connNameAfter=label;
      }
      IPath path=new Path(item.getState().getPath());
      if (ProxyRepositoryFactory.getInstance().getFolderItem(ProjectManager.getInstance().getCurrentProject(),ERepositoryObjectType.getItemType(item),path) == null) {
        ProxyRepositoryFactory.getInstance().createFolder(ERepositoryObjectType.getItemType(item),path.removeLastSegments(1),path.lastSegment());
      }
      if (isWorksapcePath()) {
        ProxyRepositoryFactory.getInstance().create(item,path,true);
        if (item instanceof ConnectionItem) {
          Connection conn=((ConnectionItem)item).getConnection();
          if (conn.eIsProxy()) {
            conn=(Connection)EObjectHelper.resolveObject(conn);
          }
          connNameAfter=conn.eResource().getURI().trimFileExtension().lastSegment();
        }
      }
 else {
        copyFile(parentFolder,propFile,property,path,connNameAfter);
      }
      if (connNameBofore != null && connNameAfter != null) {
        getReplaceStringMap().put(connNameBofore,connNameAfter);
      }
    }
  }
}