mirror of
https://github.com/ceph/ceph
synced 2025-02-21 09:57:26 +00:00
rgw: fix that we return data when partial content is requested
This commit is contained in:
parent
50a89fcb52
commit
a48b15040f
@ -217,6 +217,7 @@ int RGWGetObj_REST::get_params()
|
||||
int RGWGetObj_REST::send_response(void *handle)
|
||||
{
|
||||
const char *content_type = NULL;
|
||||
int orig_ret = ret;
|
||||
|
||||
if (sent_header)
|
||||
goto send_data;
|
||||
@ -248,7 +249,6 @@ int RGWGetObj_REST::send_response(void *handle)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if (range_str && !ret)
|
||||
ret = 206; /* partial content */
|
||||
|
||||
@ -258,7 +258,7 @@ int RGWGetObj_REST::send_response(void *handle)
|
||||
sent_header = true;
|
||||
|
||||
send_data:
|
||||
if (get_data && !ret) {
|
||||
if (get_data && !orig_ret) {
|
||||
FCGX_PutStr(data, len, s->fcgx->out);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user