Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthias Sohn2016-05-23 21:22:10 +0000
committerMatthias Sohn2016-05-31 06:56:19 +0000
commit06b7f728b3f59e81a3be017bcc39274f341e7798 (patch)
tree9462b6d021e9d7ef1776ed435292d6af9f9ba480
parent5a8fb7a309fe1cac3c71ae617ed6f1f8de839031 (diff)
downloadegit-06b7f728b3f59e81a3be017bcc39274f341e7798.tar.gz
egit-06b7f728b3f59e81a3be017bcc39274f341e7798.tar.xz
egit-06b7f728b3f59e81a3be017bcc39274f341e7798.zip
Fix NPE in CloneDestinationPage.checkPreviousPageSelections()
Bug: 494352 Change-Id: I17e57db83b08609761b75cd7ade28d4e9569930e Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
-rw-r--r--org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/clone/CloneDestinationPage.java7
1 files changed, 4 insertions, 3 deletions
diff --git a/org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/clone/CloneDestinationPage.java b/org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/clone/CloneDestinationPage.java
index 096b7c95df..94bf8879c0 100644
--- a/org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/clone/CloneDestinationPage.java
+++ b/org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/clone/CloneDestinationPage.java
@@ -146,10 +146,11 @@ public class CloneDestinationPage extends WizardPage {
List<Ref> branches, Ref head) {
if (!repositorySelection.equals(validatedRepoSelection)
|| !branches.equals(validatedSelectedBranches)
- || !head.equals(validatedHEAD))
+ || (head != null && !head.equals(validatedHEAD))) {
setPageComplete(false);
- else
+ } else {
checkPage();
+ }
}
private void createDestinationGroup(final Composite parent) {
@@ -442,7 +443,7 @@ public class CloneDestinationPage extends WizardPage {
List<Ref> branches, Ref head) {
if (repoSelection.equals(validatedRepoSelection)
&& branches.equals(validatedSelectedBranches)
- && head.equals(validatedHEAD)) {
+ && head != null && head.equals(validatedHEAD)) {
checkPage();
return;
}

Back to the top