You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@karaf.apache.org by ff...@apache.org on 2018/04/10 03:24:54 UTC
[karaf] branch master updated: [KARAF-5694]strip url to ensure it's
a valid one which could download
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 <fr...@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.