Uploaded image for project: 'Archiva (Retired)'
  1. Archiva (Retired)
  2. MRM-1434

Suspicious RepositoryMetadataMerge.clonePlugins

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Minor
    • Resolution: Unresolved
    • None
    • Backlog
    • None
    • None

    Description

      The method RepositoryMetadataMerge.clonePlugins seems oddly wrong to me, it clones a plugin, but then doesn't use the clone, but uses the original

      private static List<Plugin> clonePlugins(List<Plugin> plugins)
      {
      if (plugins == null)

      { return null; }

      List<Plugin> result = new ArrayList<Plugin>();

      for (Plugin plugin : plugins)

      { Plugin clonedPlugin = new Plugin(); clonedPlugin.setArtifactId(plugin.getArtifactId()); clonedPlugin.setName(plugin.getName()); clonedPlugin.setPrefix(plugin.getPrefix()); result.add(plugin); <======= should this be clonedPlugin ? }

      return result;
      }

      Attachments

        Activity

          People

            oching Maria Odea B. Ching
            dbrosius David Brosius
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated: