Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJohn Arthorne2008-05-02 16:11:02 -0400
committerJohn Arthorne2008-05-02 16:11:02 -0400
commit916c73918efe81aaadaee71f47d7a97da06a49a8 (patch)
tree18f533d52a007989831d8d563e61da4049ebfa83 /bundles/org.eclipse.equinox.p2.directorywatcher
parent0b6f8d377e8d797cd6792f81de51949a9d98f9a2 (diff)
downloadrt.equinox.p2-916c73918efe81aaadaee71f47d7a97da06a49a8.tar.gz
rt.equinox.p2-916c73918efe81aaadaee71f47d7a97da06a49a8.tar.xz
rt.equinox.p2-916c73918efe81aaadaee71f47d7a97da06a49a8.zip
Bug 228903 Repository manager creation should always add the repository
Diffstat (limited to 'bundles/org.eclipse.equinox.p2.directorywatcher')
-rw-r--r--bundles/org.eclipse.equinox.p2.directorywatcher/src/org/eclipse/equinox/internal/provisional/p2/directorywatcher/RepositoryListener.java8
1 files changed, 2 insertions, 6 deletions
diff --git a/bundles/org.eclipse.equinox.p2.directorywatcher/src/org/eclipse/equinox/internal/provisional/p2/directorywatcher/RepositoryListener.java b/bundles/org.eclipse.equinox.p2.directorywatcher/src/org/eclipse/equinox/internal/provisional/p2/directorywatcher/RepositoryListener.java
index ec5ac9299..a8c05ef55 100644
--- a/bundles/org.eclipse.equinox.p2.directorywatcher/src/org/eclipse/equinox/internal/provisional/p2/directorywatcher/RepositoryListener.java
+++ b/bundles/org.eclipse.equinox.p2.directorywatcher/src/org/eclipse/equinox/internal/provisional/p2/directorywatcher/RepositoryListener.java
@@ -147,9 +147,7 @@ public class RepositoryListener extends DirectoryChangeListener {
properties.put(IRepository.PROP_SYSTEM, Boolean.TRUE.toString());
name = "artifact listener " + repositoryName; //$NON-NLS-1$
}
- IArtifactRepository repository = manager.createRepository(stateDirURL, name, IArtifactRepositoryManager.TYPE_SIMPLE_REPOSITORY, properties);
- manager.addRepository(repository.getLocation());
- return repository;
+ return manager.createRepository(stateDirURL, name, IArtifactRepositoryManager.TYPE_SIMPLE_REPOSITORY, properties);
} catch (ProvisionException e) {
LogHelper.log(e);
throw new IllegalStateException(NLS.bind(Messages.failed_create_artifact_repo, stateDirURL));
@@ -179,9 +177,7 @@ public class RepositoryListener extends DirectoryChangeListener {
properties.put(IRepository.PROP_SYSTEM, Boolean.TRUE.toString());
name = "metadata listener " + repositoryName; //$NON-NLS-1$
}
- IMetadataRepository repository = manager.createRepository(stateDirURL, name, IMetadataRepositoryManager.TYPE_SIMPLE_REPOSITORY, properties);
- manager.addRepository(stateDirURL);
- return repository;
+ return manager.createRepository(stateDirURL, name, IMetadataRepositoryManager.TYPE_SIMPLE_REPOSITORY, properties);
} catch (ProvisionException e) {
LogHelper.log(e);
throw new IllegalStateException(NLS.bind(Messages.failed_create_metadata_repo, stateDirURL));

Back to the top