summaryrefslogtreecommitdiffstatsabout
diff options
context:
space:
mode:
authorMathias Kinzler2010-04-26 13:26:46 (EDT)
committer Chris Aniszczyk2010-04-26 16:12:15 (EDT)
commit8a770e3e9eb25689949495f5cc08f2dacf89ad5c (patch)
treec1dbf5a675c464c5f0d8b7ab921c71a58afde057
parent2c640f0a5463a5b86e6f7978c01f609a5c43ef2c (diff)
downloadegit-8a770e3e9eb25689949495f5cc08f2dacf89ad5c.zip
egit-8a770e3e9eb25689949495f5cc08f2dacf89ad5c.tar.gz
egit-8a770e3e9eb25689949495f5cc08f2dacf89ad5c.tar.bz2
NullPointerException during Pushrefs/changes/09/609/2
This is a bug in the RefSpecPage that leads to a NPE being logged. Change-Id: Ic02ea5c557fde959c6d20e0ba76bab16df350213 Signed-off-by: Mathias Kinzler <mathias.kinzler@sap.com> Signed-off-by: Chris Aniszczyk <caniszczyk@gmail.com>
-rw-r--r--org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/components/RefSpecPage.java35
1 files changed, 18 insertions, 17 deletions
diff --git a/org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/components/RefSpecPage.java b/org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/components/RefSpecPage.java
index 0447e09..74da373 100644
--- a/org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/components/RefSpecPage.java
+++ b/org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/components/RefSpecPage.java
@@ -272,28 +272,29 @@ public class RefSpecPage extends BaseWizardPage {
specsPanel.setAssistanceData(local, listRemotesOp.getRemoteRefs(),
actRemoteName);
- if (!pushPage) {
- tagsAutoFollowButton.setSelection(false);
- tagsFetchTagsButton.setSelection(false);
- tagsNoTagsButton.setSelection(false);
- }
-
if (newRepoSelection.isConfigSelected()) {
saveButton.setVisible(true);
saveButton.setText(NLS.bind(UIText.RefSpecPage_saveSpecifications,
actRemoteName));
saveButton.getParent().layout();
- final TagOpt tagOpt = newRepoSelection.getConfig().getTagOpt();
- switch (tagOpt) {
- case AUTO_FOLLOW:
- tagsAutoFollowButton.setSelection(true);
- break;
- case FETCH_TAGS:
- tagsFetchTagsButton.setSelection(true);
- break;
- case NO_TAGS:
- tagsNoTagsButton.setSelection(true);
- break;
+
+ if (!pushPage) {
+ tagsAutoFollowButton.setSelection(false);
+ tagsFetchTagsButton.setSelection(false);
+ tagsNoTagsButton.setSelection(false);
+
+ final TagOpt tagOpt = newRepoSelection.getConfig().getTagOpt();
+ switch (tagOpt) {
+ case AUTO_FOLLOW:
+ tagsAutoFollowButton.setSelection(true);
+ break;
+ case FETCH_TAGS:
+ tagsFetchTagsButton.setSelection(true);
+ break;
+ case NO_TAGS:
+ tagsNoTagsButton.setSelection(true);
+ break;
+ }
}
} else if (!pushPage)
tagsAutoFollowButton.setSelection(true);