Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDani Megert2013-11-06 10:29:50 -0500
committerDani Megert2013-11-06 10:29:50 -0500
commit710e2b0b8dc7efe2a971bc2cec57aeef26ba0932 (patch)
tree92985d3d2f52c483328e30b0a470b136da2231fd
parent805f2a92afb44d1a67f991c16d050a4c9506400f (diff)
downloadeclipse.platform.team-710e2b0b8dc7efe2a971bc2cec57aeef26ba0932.tar.gz
eclipse.platform.team-710e2b0b8dc7efe2a971bc2cec57aeef26ba0932.tar.xz
eclipse.platform.team-710e2b0b8dc7efe2a971bc2cec57aeef26ba0932.zip
Fixed bug 311843: CompareUIPlugin.getCommonType() returns null if left or right side is not available
Signed-off-by: Carsten Pfeiffer <carsten.pfeiffer@gebit.de>
-rw-r--r--bundles/org.eclipse.compare/compare/org/eclipse/compare/internal/CompareUIPlugin.java6
1 files changed, 2 insertions, 4 deletions
diff --git a/bundles/org.eclipse.compare/compare/org/eclipse/compare/internal/CompareUIPlugin.java b/bundles/org.eclipse.compare/compare/org/eclipse/compare/internal/CompareUIPlugin.java
index 7dc68f7a3..f88b6a398 100644
--- a/bundles/org.eclipse.compare/compare/org/eclipse/compare/internal/CompareUIPlugin.java
+++ b/bundles/org.eclipse.compare/compare/org/eclipse/compare/internal/CompareUIPlugin.java
@@ -7,6 +7,7 @@
*
* Contributors:
* IBM Corporation - initial API and implementation
+ * Carsten Pfeiffer <carsten.pfeiffer@gebit.de> - CompareUIPlugin.getCommonType() returns null if left or right side is not available - https://bugs.eclipse.org/311843
*******************************************************************************/
package org.eclipse.compare.internal;
@@ -53,6 +54,7 @@ import org.eclipse.core.runtime.Platform;
import org.eclipse.core.runtime.Status;
import org.eclipse.core.runtime.content.IContentType;
import org.eclipse.core.runtime.content.IContentTypeManager;
+
import org.eclipse.jface.dialogs.MessageDialog;
import org.eclipse.jface.operation.IRunnableContext;
import org.eclipse.jface.preference.IPreferenceStore;
@@ -1198,13 +1200,9 @@ public final class CompareUIPlugin extends AbstractUIPlugin {
type= getContentType(left);
if (type != null)
types[n++]= type;
- else
- return null;
type= getContentType(right);
if (type != null)
types[n++]= type;
- else
- return null;
IContentType result= null;
IContentType[] s0, s1, s2;

Back to the top