mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-08-01 21:35:40 +02:00
[241288] - temporary fix - trying to avoid dead-lock on import
This commit is contained in:
parent
1b041f56b4
commit
77b67de31f
1 changed files with 5 additions and 4 deletions
|
@ -122,7 +122,7 @@ public class CConfigBasedDescriptorManager implements ICDescriptorManager {
|
||||||
if (dr.getProjectOwner().getID().equals(NULLCOwner.getOwnerID())) {
|
if (dr.getProjectOwner().getID().equals(NULLCOwner.getOwnerID())) {
|
||||||
// non owned descriptors are simply configure to the new owner no questions ask!
|
// non owned descriptors are simply configure to the new owner no questions ask!
|
||||||
dr = updateDescriptor(project, dr, id);
|
dr = updateDescriptor(project, dr, id);
|
||||||
dr.apply(true);
|
|
||||||
} else if (!dr.getProjectOwner().getID().equals(id)) {
|
} else if (!dr.getProjectOwner().getID().equals(id)) {
|
||||||
IStatus status = new Status(IStatus.ERROR, CCorePlugin.PLUGIN_ID, CCorePlugin.STATUS_CDTPROJECT_EXISTS,
|
IStatus status = new Status(IStatus.ERROR, CCorePlugin.PLUGIN_ID, CCorePlugin.STATUS_CDTPROJECT_EXISTS,
|
||||||
CCorePlugin.getResourceString("CDescriptorManager.exception.alreadyConfigured"), //$NON-NLS-1$
|
CCorePlugin.getResourceString("CDescriptorManager.exception.alreadyConfigured"), //$NON-NLS-1$
|
||||||
|
@ -135,7 +135,7 @@ public class CConfigBasedDescriptorManager implements ICDescriptorManager {
|
||||||
// try {
|
// try {
|
||||||
dr = findDescriptor(project, true);
|
dr = findDescriptor(project, true);
|
||||||
dr = updateDescriptor(project, dr, id);
|
dr = updateDescriptor(project, dr, id);
|
||||||
dr.apply(true);
|
|
||||||
// } catch (CoreException e) { // if .cdtproject already exists we'll use that
|
// } catch (CoreException e) { // if .cdtproject already exists we'll use that
|
||||||
// IStatus status = e.getStatus();
|
// IStatus status = e.getStatus();
|
||||||
// if (status.getCode() == CCorePlugin.STATUS_CDTPROJECT_EXISTS) {
|
// if (status.getCode() == CCorePlugin.STATUS_CDTPROJECT_EXISTS) {
|
||||||
|
@ -146,6 +146,7 @@ public class CConfigBasedDescriptorManager implements ICDescriptorManager {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
dr.apply(true);
|
||||||
if(dr.isOperationStarted())
|
if(dr.isOperationStarted())
|
||||||
dr.setOpEvent(new CDescriptorEvent(dr, CDescriptorEvent.CDTPROJECT_ADDED, 0));
|
dr.setOpEvent(new CDescriptorEvent(dr, CDescriptorEvent.CDTPROJECT_ADDED, 0));
|
||||||
}
|
}
|
||||||
|
@ -185,9 +186,9 @@ public class CConfigBasedDescriptorManager implements ICDescriptorManager {
|
||||||
|
|
||||||
synchronized(CProjectDescriptionManager.getInstance()){
|
synchronized(CProjectDescriptionManager.getInstance()){
|
||||||
dr = updateDescriptor(project, dr, id);
|
dr = updateDescriptor(project, dr, id);
|
||||||
dr.apply(true);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
dr.apply(true);
|
||||||
if(dr.isOperationStarted())
|
if(dr.isOperationStarted())
|
||||||
dr.setOpEvent(new CDescriptorEvent(dr, CDescriptorEvent.CDTPROJECT_CHANGED, CDescriptorEvent.OWNER_CHANGED));
|
dr.setOpEvent(new CDescriptorEvent(dr, CDescriptorEvent.CDTPROJECT_CHANGED, CDescriptorEvent.OWNER_CHANGED));
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue