Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/p2/engine/ProvisioningContext.java')
-rw-r--r--bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/p2/engine/ProvisioningContext.java11
1 files changed, 7 insertions, 4 deletions
diff --git a/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/p2/engine/ProvisioningContext.java b/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/p2/engine/ProvisioningContext.java
index 2308effd9..f9ab50bfb 100644
--- a/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/p2/engine/ProvisioningContext.java
+++ b/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/p2/engine/ProvisioningContext.java
@@ -156,16 +156,19 @@ public class ProvisioningContext {
List<IArtifactRepository> repos = new ArrayList<>();
SubMonitor sub = SubMonitor.convert(monitor, (repositories.length + 1) * 100);
for (int i = 0; i < repositories.length; i++) {
- if (sub.isCanceled())
+ if (sub.isCanceled()) {
throw new OperationCanceledException();
+ }
+ URI location = repositories[i];
try {
- repos.add(repoManager.loadRepository(repositories[i], sub.newChild(100)));
+ repos.add(repoManager.loadRepository(location, sub.newChild(100)));
} catch (ProvisionException e) {
//skip unreadable repositories
}
// Remove this URI from the list of extra references if it is there.
- if (referencedArtifactRepositories != null)
- referencedArtifactRepositories.remove(repositories[i]);
+ if (referencedArtifactRepositories != null && location != null) {
+ referencedArtifactRepositories.remove(location.toString());
+ }
}
// Are there any extra artifact repository references to consider?
if (referencedArtifactRepositories != null && referencedArtifactRepositories.size() > 0 && shouldFollowArtifactReferences()) {

Back to the top