summaryrefslogtreecommitdiff
path: root/horizon/horizon/dashboards/nova/containers/views.py
diff options
context:
space:
mode:
Diffstat (limited to 'horizon/horizon/dashboards/nova/containers/views.py')
-rw-r--r--horizon/horizon/dashboards/nova/containers/views.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/horizon/horizon/dashboards/nova/containers/views.py b/horizon/horizon/dashboards/nova/containers/views.py
index 6cfc3c4e2..4b31ec5df 100644
--- a/horizon/horizon/dashboards/nova/containers/views.py
+++ b/horizon/horizon/dashboards/nova/containers/views.py
@@ -122,7 +122,8 @@ def object_download(request, container_name, object_name):
_("Unable to retrieve object."),
redirect=redirect)
response = http.HttpResponse()
- response['Content-Disposition'] = 'attachment; filename=%s' % filename
+ safe_name = filename.encode('utf-8')
+ response['Content-Disposition'] = 'attachment; filename=%s' % safe_name
response['Content-Type'] = 'application/octet-stream'
for data in object_data:
response.write(data)