Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSteffen Pingel2012-02-29 10:10:27 -0500
committerSteffen Pingel2012-02-29 10:11:57 -0500
commitb451ffd6631fb352f618eb3a77fecf8fb89ac21f (patch)
tree0665af3fd7ca467b8d331e455483b2695982ce31 /org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks
parent2952584b62acdfc6ada2c532f41717cfed9e73ea (diff)
downloadorg.eclipse.mylyn.tasks-b451ffd6631fb352f618eb3a77fecf8fb89ac21f.tar.gz
org.eclipse.mylyn.tasks-b451ffd6631fb352f618eb3a77fecf8fb89ac21f.tar.xz
org.eclipse.mylyn.tasks-b451ffd6631fb352f618eb3a77fecf8fb89ac21f.zip
NEW - bug 372837: NullPointerException when opening Gerrit search page
https://bugs.eclipse.org/bugs/show_bug.cgi?id=372837
Diffstat (limited to 'org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks')
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/wizards/AbstractRepositoryQueryPage2.java16
1 files changed, 10 insertions, 6 deletions
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/wizards/AbstractRepositoryQueryPage2.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/wizards/AbstractRepositoryQueryPage2.java
index da1b20e0d..3481bdf12 100644
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/wizards/AbstractRepositoryQueryPage2.java
+++ b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/wizards/AbstractRepositoryQueryPage2.java
@@ -167,7 +167,9 @@ public abstract class AbstractRepositoryQueryPage2 extends AbstractRepositoryQue
applyTo(query);
IDialogSettings settings = getDialogSettings();
- settings.put(getSavedStateSettingKey(), query.getUrl());
+ if (settings != null) {
+ settings.put(getSavedStateSettingKey(), query.getUrl());
+ }
}
}
@@ -425,11 +427,13 @@ public abstract class AbstractRepositoryQueryPage2 extends AbstractRepositoryQue
protected boolean restoreSavedState() {
IDialogSettings settings = getDialogSettings();
- String queryUrl = settings.get(getSavedStateSettingKey());
- if (queryUrl != null) {
- RepositoryQuery query = new RepositoryQuery(getTaskRepository().getConnectorKind(), "handle"); //$NON-NLS-1$
- query.setUrl(queryUrl);
- return restoreState(query);
+ if (settings != null) {
+ String queryUrl = settings.get(getSavedStateSettingKey());
+ if (queryUrl != null) {
+ RepositoryQuery query = new RepositoryQuery(getTaskRepository().getConnectorKind(), "handle"); //$NON-NLS-1$
+ query.setUrl(queryUrl);
+ return restoreState(query);
+ }
}
return false;
}

Back to the top