karaf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ff...@apache.org
Subject [karaf] branch master updated: [KARAF-5694]strip url to ensure it's a valid one which could download
Date Tue, 10 Apr 2018 03:24:54 GMT
This is an automated email from the ASF dual-hosted git repository.

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


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

commit f434e39d9b632e1093b6790341c02ed263261d9f
Author: Freeman Fang <freeman.fang@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
---
 .../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 2dbf481..527c3a3 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
ffang@apache.org.

Mime
View raw message