summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPascal Rapicault2013-01-21 11:28:20 (EST)
committerPascal Rapicault2013-01-21 11:28:20 (EST)
commitba5f048a3ac5563430104adeb173dc4f7dda6eca (patch)
tree833b38d44f4c7c5c7dff9c750ca46b1437e9e318
parentd81a08fef5a310b3ef4fedb8ab625972b0c18b58 (diff)
downloadrt.equinox.p2-ba5f048a3ac5563430104adeb173dc4f7dda6eca.zip
rt.equinox.p2-ba5f048a3ac5563430104adeb173dc4f7dda6eca.tar.gz
rt.equinox.p2-ba5f048a3ac5563430104adeb173dc4f7dda6eca.tar.bz2
Bug 398539 - Got a NPE trying to add a new update site
-rw-r--r--bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/p2/ui/RepositoryManipulationPage.java5
1 files changed, 3 insertions, 2 deletions
diff --git a/bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/p2/ui/RepositoryManipulationPage.java b/bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/p2/ui/RepositoryManipulationPage.java
index 73b63c7..914f56c 100644
--- a/bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/p2/ui/RepositoryManipulationPage.java
+++ b/bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/p2/ui/RepositoryManipulationPage.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2007, 2012 IBM Corporation and others.
+ * Copyright (c) 2007, 2013 IBM Corporation and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
@@ -7,6 +7,7 @@
*
* Contributors:
* IBM Corporation - initial API and implementation
+ * Ericsson AB (Pascal Rapicault) - bug 398539
*******************************************************************************/
package org.eclipse.equinox.p2.ui;
@@ -774,7 +775,7 @@ public class RepositoryManipulationPage extends PreferencePage implements IWorkb
};
int retCode = dialog.open();
- if (retCode == Window.OK) {
+ if (retCode == Window.OK && dialog.getLocation() != null) {
selected[0].setNickname(dialog.getName());
selected[0].setLocation(dialog.getLocation());
if (dialog.getLocation().equals(existingLocation)) {