This is an automated email from the ASF dual-hosted git repository.

ffang pushed a commit to branch karaf-4.1.x
in repository https://gitbox.apache.org/repos/asf/karaf.git


The following commit(s) were added to refs/heads/karaf-4.1.x by this push:
     new 2f9dffa  [KARAF-5694]strip url to ensure it's a valid one which could 
download
2f9dffa is described below

commit 2f9dffa679eeea122a1cc5d3d6b1a856937b5377
Author: Freeman Fang <freeman.f...@gmail.com>
AuthorDate: Tue Apr 10 11:24:42 2018 +0800

    [KARAF-5694]strip url to ensure it's a valid one which could download
    
    (cherry picked from commit f434e39d9b632e1093b6790341c02ed263261d9f)
---
 .../karaf/features/internal/download/impl/SimpleDownloadTask.java      | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git 
a/features/core/src/main/java/org/apache/karaf/features/internal/download/impl/SimpleDownloadTask.java
 
b/features/core/src/main/java/org/apache/karaf/features/internal/download/impl/SimpleDownloadTask.java
index 6e8c079..633bf23 100644
--- 
a/features/core/src/main/java/org/apache/karaf/features/internal/download/impl/SimpleDownloadTask.java
+++ 
b/features/core/src/main/java/org/apache/karaf/features/internal/download/impl/SimpleDownloadTask.java
@@ -72,7 +72,8 @@ public class SimpleDownloadTask extends 
AbstractRetryableDownloadTask {
             }
 
             File tmpFile = File.createTempFile("download-", null, dir);
-
+            
+            urlObj = new 
URL(DownloadManagerHelper.stripUrl(urlObj.toString()));
             try (InputStream is = urlObj.openStream();
                  OutputStream os = new FileOutputStream(tmpFile)) {
                 StreamUtils.copy(is, os);

-- 
To stop receiving notification emails like this one, please contact
ff...@apache.org.

Reply via email to