eclipse/eclipse-workaround-plugin.xml-parsing-bug-gcc-bz29853.patch

23 lines
1.1 KiB
Diff
Raw Normal View History

Index: src/org/eclipse/pde/internal/core/plugin/PluginHandler.java
===================================================================
RCS file: /cvsroot/eclipse/org.eclipse.pde.core/src/org/eclipse/pde/internal/core/plugin/PluginHandler.java,v
retrieving revision 1.6
diff -u -r1.6 PluginHandler.java
--- src/org/eclipse/pde/internal/core/plugin/PluginHandler.java 3 Apr 2006 19:48:18 -0000 1.6
+++ src/org/eclipse/pde/internal/core/plugin/PluginHandler.java 17 Nov 2006 22:18:53 -0000
@@ -52,11 +52,13 @@
}
}
+ boolean setLineAttr = false;
Element element = fDocument.createElement(qName);
for (int i = 0; i < attributes.getLength(); i++) {
element.setAttribute(attributes.getQName(i), attributes.getValue(i));
- if ("extension".equals(qName) || "extension-point".equals(qName)) { //$NON-NLS-1$ //$NON-NLS-2$
+ if (("extension".equals(qName) || "extension-point".equals(qName)) && !setLineAttr) { //$NON-NLS-1$ //$NON-NLS-2$
element.setAttribute("line", Integer.toString(fLocator.getLineNumber())); //$NON-NLS-1$
+ setLineAttr = true;
}
}