Author: xavier
Date: Sat Jan 26 03:37:13 2008
New Revision: 615446

URL: http://svn.apache.org/viewvc?rev=615446&view=rev
Log:
FIX: NPE when calling retrieve if some artifacts are not available locally 
(IVY-712)

Modified:
    ant/ivy/core/trunk/CHANGES.txt
    ant/ivy/core/trunk/src/java/org/apache/ivy/core/retrieve/RetrieveEngine.java

Modified: ant/ivy/core/trunk/CHANGES.txt
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/CHANGES.txt?rev=615446&r1=615445&r2=615446&view=diff
==============================================================================
--- ant/ivy/core/trunk/CHANGES.txt (original)
+++ ant/ivy/core/trunk/CHANGES.txt Sat Jan 26 03:37:13 2008
@@ -76,6 +76,7 @@
 - IMPROVEMENT: Downgrade Ant version requirement to 1.6 to build Ivy (IVY-687)
 - IMPROVEMENT: In the ResolveReport class, add the possibility to filter the 
evicted module while getting the list of DownloadArtifact (IVY-704) (thanks to 
Nicolas Lalevée)
 
+- FIX: NPE when calling retrieve if some artifacts are not available locally 
(IVY-712)
 - FIX: When in ssh plugin we does not set username in scheme, Ivy always try 
to connect with guest username, even if we change one in panel. (IVY-710) 
(thanks to Ruslan Shevchenko)
 - FIX: NPE in SshCache during publish with ssh resolver without passFile 
(IVY-709) (thanks to Ruslan Shevchenko)
 - FIX: Update install ivy build file example (IVY-705) (thanks to Benjamin 
Francisoud)

Modified: 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/retrieve/RetrieveEngine.java
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/core/retrieve/RetrieveEngine.java?rev=615446&r1=615445&r2=615446&view=diff
==============================================================================
--- 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/retrieve/RetrieveEngine.java 
(original)
+++ 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/retrieve/RetrieveEngine.java 
Sat Jan 26 03:37:13 2008
@@ -107,6 +107,10 @@
             for (Iterator iter = artifactsToCopy.keySet().iterator(); 
iter.hasNext();) {
                 ArtifactDownloadReport artifact = (ArtifactDownloadReport) 
iter.next();
                 File archive = artifact.getLocalFile();
+                if (archive == null) {
+                    Message.verbose("\tno local file available for " + 
artifact + ": skipping");
+                    continue;
+                }
                 Set dest = (Set) artifactsToCopy.get(artifact);
                 Message.verbose("\tretrieving " + archive);
                 for (Iterator it2 = dest.iterator(); it2.hasNext();) {


Reply via email to