You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@allura.apache.org by br...@apache.org on 2015/07/08 00:11:28 UTC

[11/16] allura git commit: [#7899] ticket:808 Fixed downloading repo files with spaces

[#7899] ticket:808 Fixed downloading repo files with spaces


Project: http://git-wip-us.apache.org/repos/asf/allura/repo
Commit: http://git-wip-us.apache.org/repos/asf/allura/commit/fdefe42f
Tree: http://git-wip-us.apache.org/repos/asf/allura/tree/fdefe42f
Diff: http://git-wip-us.apache.org/repos/asf/allura/diff/fdefe42f

Branch: refs/heads/db/6373
Commit: fdefe42fb654ca105d05c302a351edf0a49f9d4d
Parents: 6991e51
Author: Aleksey 'LXj' Alekseyev <go...@gmail.com>
Authored: Sun Jun 28 13:18:02 2015 +0300
Committer: Igor Bondarenko <je...@gmail.com>
Committed: Mon Jul 6 15:12:34 2015 +0300

----------------------------------------------------------------------
 Allura/allura/controllers/repository.py | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/allura/blob/fdefe42f/Allura/allura/controllers/repository.py
----------------------------------------------------------------------
diff --git a/Allura/allura/controllers/repository.py b/Allura/allura/controllers/repository.py
index 4c9cb83..e9f051d 100644
--- a/Allura/allura/controllers/repository.py
+++ b/Allura/allura/controllers/repository.py
@@ -738,7 +738,8 @@ class FileBrowser(BaseController):
             response.headers['Content-Encoding'] = ''
             response.content_encoding = content_encoding
         response.headers.add(
-            'Content-Disposition', 'attachment;filename=' + filename)
+            'Content-Disposition',
+            'attachment;filename="%s"' % filename.encode('utf-8'))
         return iter(self._blob)
 
     def diff(self, commit, fmt=None, **kw):