Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Valenta2002-06-10 18:43:06 +0000
committerMichael Valenta2002-06-10 18:43:06 +0000
commitb8ee31ccda2c5edae0b62e055d46d47dba614105 (patch)
tree107524662c527ef88d9d8ba6b9196f3cfe15a0cc
parent219d6ffea833311b7e7e5fb962d71faf766df692 (diff)
downloadeclipse.platform.team-b8ee31ccda2c5edae0b62e055d46d47dba614105.tar.gz
eclipse.platform.team-b8ee31ccda2c5edae0b62e055d46d47dba614105.tar.xz
eclipse.platform.team-b8ee31ccda2c5edae0b62e055d46d47dba614105.zip
19232: Internal errors after checking out many projectsI20020611
-rw-r--r--bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/messages.properties1
-rw-r--r--bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/resources/EclipseSynchronizer.java15
2 files changed, 13 insertions, 3 deletions
diff --git a/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/messages.properties b/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/messages.properties
index b84a44556..8a44d4684 100644
--- a/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/messages.properties
+++ b/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/messages.properties
@@ -243,6 +243,7 @@ EclipseSynchronizer.ErrorSettingFolderSync=Cannot set folder sync info on {0}
EclipseSynchronizer.ErrorSettingResourceSync=Cannot set resource sync info on {0}
EclipseSynchronizer.ErrorSettingIgnorePattern=Cannot set ignored pattern on {0}
EclipseSynchronizer.ErrorCommitting=Errors saving CVS synchronization information to disk. Please fix the problems listed below and then update the affected resources from the CVS repository.
+EclipseSynchronizer.folderSyncInfoMissing=CVS synchronization information could not be found for folder ''{0}''
SyncFileChangeListener.errorSettingTeamPrivateFlag=Error setting team-private flag on resource
diff --git a/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/resources/EclipseSynchronizer.java b/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/resources/EclipseSynchronizer.java
index 944093c09..666159d64 100644
--- a/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/resources/EclipseSynchronizer.java
+++ b/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/resources/EclipseSynchronizer.java
@@ -624,7 +624,10 @@ public class EclipseSynchronizer {
try {
IContainer parent = resource.getParent();
HashMap children = (HashMap)resource.getParent().getSessionProperty(RESOURCE_SYNC_KEY);
- Assert.isNotNull(children);
+ if (children == null) {
+ // There should be sync info but it was missing. Report the error
+ throw new CVSException(Policy.bind("EclipseSynchronizer.folderSyncInfoMissing", parent.getFullPath().toString())); //$NON-NLS-1$
+ }
return (ResourceSyncInfo) children.get(resource.getName());
} catch(CoreException e) {
throw CVSException.wrapException(e);
@@ -667,7 +670,10 @@ public class EclipseSynchronizer {
private static Collection /* of ResourceSyncInfo */ getCachedResourceSyncForChildren(IContainer container) throws CVSException {
try {
HashMap children = (HashMap)container.getSessionProperty(RESOURCE_SYNC_KEY);
- Assert.isNotNull(children);
+ if (children == null) {
+ // There should be sync info but it was missing. Report the error
+ throw new CVSException(Policy.bind("EclipseSynchronizer.folderSyncInfoMissing", container.getFullPath().toString())); //$NON-NLS-1$
+ }
return children.values();
} catch(CoreException e) {
throw CVSException.wrapException(e);
@@ -735,7 +741,10 @@ public class EclipseSynchronizer {
private static FolderSyncInfo getCachedFolderSync(IContainer container) throws CVSException {
try {
FolderSyncInfo info = (FolderSyncInfo)container.getSessionProperty(FOLDER_SYNC_KEY);
- Assert.isNotNull(info);
+ if (info == null) {
+ // There should be sync info but it was missing. Report the error
+ throw new CVSException(Policy.bind("EclipseSynchronizer.folderSyncInfoMissing", container.getFullPath().toString())); //$NON-NLS-1$
+ }
if (info == NULL_FOLDER_SYNC_INFO) return null;
return info;
} catch (CoreException e) {

Back to the top