diff options
author | Michael Valenta | 2004-05-13 01:55:42 +0000 |
---|---|---|
committer | Michael Valenta | 2004-05-13 01:55:42 +0000 |
commit | b3604fa6ecd7125aee849359d731aed076108682 (patch) | |
tree | 6b53ca287159d4067edc4cf98d75d1f0ce8bc244 | |
parent | a832ba0552f3c1b3c8bfd32a723c44e455852907 (diff) | |
download | eclipse.platform.team-branch_20040512_CVSVariantTreeExperiements.tar.gz eclipse.platform.team-branch_20040512_CVSVariantTreeExperiements.tar.xz eclipse.platform.team-branch_20040512_CVSVariantTreeExperiements.zip |
*** empty log message ***branch_20040512_CVSVariantTreeExperiements
-rw-r--r-- | bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/syncinfo/CVSResourceVariantTree.java | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/syncinfo/CVSResourceVariantTree.java b/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/syncinfo/CVSResourceVariantTree.java index 814986e48..c4bdcbfdd 100644 --- a/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/syncinfo/CVSResourceVariantTree.java +++ b/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/syncinfo/CVSResourceVariantTree.java @@ -280,14 +280,17 @@ public class CVSResourceVariantTree extends ResourceVariantTree { protected IResource[] refresh(IResource resource, int depth, IProgressMonitor monitor) throws TeamException { IResource[] changedResources = null; monitor.beginTask(null, 100); - // Wait indefinitely until buidl is done - while (isJobInFamilyRunning(ResourcesPlugin.FAMILY_AUTO_BUILD) - || isJobInFamilyRunning(ResourcesPlugin.FAMILY_MANUAL_BUILD)) { + // Wait up to 10 seconds for build to finish + int count = 0; + while (count < 10 + && (isJobInFamilyRunning(ResourcesPlugin.FAMILY_AUTO_BUILD) + || isJobInFamilyRunning(ResourcesPlugin.FAMILY_MANUAL_BUILD))) { try { Thread.sleep(1000); } catch (InterruptedException e) { // Conitinue } + count++; Policy.checkCanceled(monitor); } ISchedulingRule rule = getSchedulingRule(resource); |