Maven Ant Tasks
  1. Maven Ant Tasks
  2. MANTTASKS-98

NPE if user settings file doesn't exist

    Details

    • Type: Bug Bug
    • Status: Closed Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 2.0.8
    • Fix Version/s: 2.0.8
    • Component/s: pom task
    • Labels:
      None
    • Environment:
      2.0.08-SNAPSHOT from 18-Nov-2007
    • Number of attachments :
      1

      Description

      When running

      <artifact:install file="/path/to/file.jar">
      <pom file="/path/to/pom.xml" />
      <remoteRepository refId="repo" />
      </artifact:install>

      you get, if ~/.m2/settings.xml is missing,

      java.lang.NullPointerException
      at org.apache.maven.settings.SettingsUtils.merge(SettingsUtils.java:110)
      at org.apache.maven.artifact.ant.AbstractArtifactTask.initSettings(Abstr
      actArtifactTask.java:264)
      at org.apache.maven.artifact.ant.AbstractArtifactTask.execute(AbstractAr
      tifactTask.java:643)
      at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288)
      at sun.reflect.GeneratedMethodAccessor2.invoke(Unknown Source)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
      sorImpl.java:25)

        Activity

        Hide
        Pete Muir added a comment -

        Patch to fix

        Show
        Pete Muir added a comment - Patch to fix
        Hide
        Herve Boutemy added a comment -

        fixed, thank you

        Show
        Herve Boutemy added a comment - fixed, thank you

          People

          • Assignee:
            Herve Boutemy
            Reporter:
            Pete Muir
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: