Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChristian Halstrick2011-02-06 19:07:39 -0500
committerMatthias Sohn2011-02-07 11:52:00 -0500
commit16c06f38e63450194bb59286c0fd5cda64d0bb5c (patch)
tree6840a3ba5b5cf8fa35fe77a2f9aba4c024a2cb9d
parentcd689c91191fe36ec34be7b70266b524f94ea04f (diff)
downloadegit-16c06f38e63450194bb59286c0fd5cda64d0bb5c.tar.gz
egit-16c06f38e63450194bb59286c0fd5cda64d0bb5c.tar.xz
egit-16c06f38e63450194bb59286c0fd5cda64d0bb5c.zip
Fixed broken GitImportWizard
The GitImportWizard was throwing ArrayIndexOutOfBoundsException when trying to import as "General Project". Change-Id: Id0d56888c8541738155f3c375f2a919a50cd37e4 Signed-off-by: Christian Halstrick <christian.halstrick@sap.com> Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
-rw-r--r--org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/clone/GitImportWizard.java10
1 files changed, 5 insertions, 5 deletions
diff --git a/org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/clone/GitImportWizard.java b/org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/clone/GitImportWizard.java
index 22008d7f6..b2bde7710 100644
--- a/org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/clone/GitImportWizard.java
+++ b/org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/clone/GitImportWizard.java
@@ -166,7 +166,7 @@ public class GitImportWizard extends Wizard implements IImportWizard {
final File[] repoDir = new File[1];
PlatformUI.getWorkbench().getDisplay().syncExec(new Runnable() {
public void run() {
- repoDir[1] = selectRepoPage.getRepository().getDirectory();
+ repoDir[0] = selectRepoPage.getRepository().getDirectory();
}
});
final List<IProject> previousProjects = Arrays
@@ -201,7 +201,7 @@ public class GitImportWizard extends Wizard implements IImportWizard {
}
case GitSelectWizardPage.GENERAL_WIZARD: {
final String[] projectName = new String[1];
- final boolean[] defaultLocation = new boolean[0];
+ final boolean[] defaultLocation = new boolean[1];
final String[] path = new String[1];
final File[] repoDir = new File[1];
// get the data from the page in the UI thread
@@ -210,8 +210,8 @@ public class GitImportWizard extends Wizard implements IImportWizard {
projectName[0] = createGeneralProjectPage.getProjectName();
defaultLocation[0] = createGeneralProjectPage
.isDefaultLocation();
- path[1] = importWithDirectoriesPage.getPath();
- repoDir[1] = selectRepoPage.getRepository().getDirectory();
+ path[0] = importWithDirectoriesPage.getPath();
+ repoDir[0] = selectRepoPage.getRepository().getDirectory();
}
});
try {
@@ -228,7 +228,7 @@ public class GitImportWizard extends Wizard implements IImportWizard {
prj.create(desc, actMonitor);
prj.open(actMonitor);
ConnectProviderOperation cpo = new ConnectProviderOperation(
- prj, repoDir[1]);
+ prj, repoDir[0]);
cpo.execute(new NullProgressMonitor());
ResourcesPlugin.getWorkspace().getRoot().refreshLocal(

Back to the top