Bug in plexus-utils leads to NPE when using PI in large POMs
Closed this issue · 1 comments
johanneskraemer commented
When using a Processing Instruction (e.g. <?m2e) in a large POM, plexus-utils throws a NPE:
We got an exception on merge: merge --base=.merge_file_a09220 --our=.merge_file_b09220 --their=.merge_file_c09220 --ruleset=./merge/ruleset.yaml
java.lang.ArrayIndexOutOfBoundsException: 8306
at org.codehaus.plexus.util.xml.pull.MXParser.parsePI(MXParser.java:2502)
at org.codehaus.plexus.util.xml.pull.MXParser.nextImpl(MXParser.java:1283)
at org.codehaus.plexus.util.xml.pull.MXParser.next(MXParser.java:1131)
at org.codehaus.plexus.util.xml.pull.MXParser.nextTag(MXParser.java:1116)
at org.apache.maven.model.io.xpp3.MavenXpp3Reader.parsePluginExecution(MavenXpp3Reader.java:2741)
at org.apache.maven.model.io.xpp3.MavenXpp3Reader.parsePlugin(MavenXpp3Reader.java:2552)
at org.apache.maven.model.io.xpp3.MavenXpp3Reader.parseBuild(MavenXpp3Reader.java:799)
at org.apache.maven.model.io.xpp3.MavenXpp3Reader.parseModel(MavenXpp3Reader.java:1996)
at org.apache.maven.model.io.xpp3.MavenXpp3Reader.read(MavenXpp3Reader.java:3912)
at org.apache.maven.model.io.xpp3.MavenXpp3Reader.read(MavenXpp3Reader.java:3926)
at org.codehaus.mojo.versions.api.PomHelper.getRawModel(PomHelper.java:128)
at de.oppermann.pomutils.util.POM.initialize(POM.java:103)
at de.oppermann.pomutils.util.POM.<init>(POM.java:90)
at de.oppermann.pomutils.PomMergeDriver.merge(PomMergeDriver.java:61)
at de.oppermann.pomutils.Main.executePomMergeDriver(Main.java:98)
at de.oppermann.pomutils.Main.mainInternal(Main.java:85)
at de.oppermann.pomutils.Main.main(Main.java:49)