Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrey Loskutov2014-12-19 22:53:00 +0000
committerMatthias Sohn2014-12-31 01:15:40 +0000
commit730d9b72bc4646f012f197ef5c1ca2238c2f92a5 (patch)
tree8dd94c4755336d8455d58a57aea1d344f4ace143
parent0da6579c4ccec3fb70401f178a6712f2e338519d (diff)
downloadegit-730d9b72bc4646f012f197ef5c1ca2238c2f92a5.tar.gz
egit-730d9b72bc4646f012f197ef5c1ca2238c2f92a5.tar.xz
egit-730d9b72bc4646f012f197ef5c1ca2238c2f92a5.zip
Avoid iterating on deleted repositories in IteratorService
Bug: 455815 Change-Id: I01c593c8a53f3a1e8a44de1e21698f334da9c713 Signed-off-by: Andrey Loskutov <loskutov@gmx.de>
-rw-r--r--org.eclipse.egit.core/src/org/eclipse/egit/core/IteratorService.java5
1 files changed, 4 insertions, 1 deletions
diff --git a/org.eclipse.egit.core/src/org/eclipse/egit/core/IteratorService.java b/org.eclipse.egit.core/src/org/eclipse/egit/core/IteratorService.java
index f2f1a7987b..1d2b4f2b2e 100644
--- a/org.eclipse.egit.core/src/org/eclipse/egit/core/IteratorService.java
+++ b/org.eclipse.egit.core/src/org/eclipse/egit/core/IteratorService.java
@@ -45,7 +45,10 @@ public class IteratorService {
// workspace is closed
return null;
}
- IContainer container = findContainer(root, repository.getWorkTree());
+ File workTree = repository.getWorkTree();
+ if (!workTree.exists())
+ return null;
+ IContainer container = findContainer(root, workTree);
if (container != null)
return new ContainerTreeIterator(repository, container);
return new AdaptableFileTreeIterator(repository, root);

Back to the top