From b25212ab234fc9c7c90c02baa1e1152d67caee3f Mon Sep 17 00:00:00 2001 From: yuliyang Date: Mon, 11 Sep 2017 16:22:55 +0800 Subject: [PATCH] rgw: return 'Access-Control-Allow-Origin' header when the set and delete bucket website through XMLHttpRequest Signed-off-by: yuliyang --- src/rgw/rgw_rest_s3.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/rgw/rgw_rest_s3.cc b/src/rgw/rgw_rest_s3.cc index 024ac4a0229f5..295890dc96ebb 100644 --- a/src/rgw/rgw_rest_s3.cc +++ b/src/rgw/rgw_rest_s3.cc @@ -1014,7 +1014,7 @@ void RGWSetBucketWebsite_ObjStore_S3::send_response() if (op_ret < 0) set_req_state_err(s, op_ret); dump_errno(s); - end_header(s); + end_header(s, this, "application/xml"); } void RGWDeleteBucketWebsite_ObjStore_S3::send_response() @@ -1024,7 +1024,7 @@ void RGWDeleteBucketWebsite_ObjStore_S3::send_response() } set_req_state_err(s, op_ret); dump_errno(s); - end_header(s); + end_header(s, this, "application/xml"); } void RGWGetBucketWebsite_ObjStore_S3::send_response() -- 2.39.5