1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-08-11 18:25:40 +02:00

Bug 186306: possible tool's NULL name.

This commit is contained in:
Oleg Krasilnikov 2007-05-10 09:13:06 +00:00
parent d6d4754b00
commit a3961ab19f

View file

@ -31,7 +31,11 @@ public class BuildListComparator extends CDTListComparator {
if (a instanceof ITool) {
ITool c1 = (ITool)a;
ITool c2 = (ITool)b;
return c1.getName().compareToIgnoreCase(c2.getName());
String s1 = c1.getName();
if (s1 == null) s1 = ""; //$NON-NLS-1$
String s2 = c2.getName();
if (s2 == null) s2 = ""; //$NON-NLS-1$
return s2.compareToIgnoreCase(s2);
}
if (a instanceof IBuildPropertyValue) {
IBuildPropertyValue c1 = (IBuildPropertyValue)a;