mirror of
https://github.com/ceph/ceph
synced 2025-02-23 02:57:21 +00:00
rgw: copy_object should not override ETAG implicitly
When copying an object with new attrs, we still need to maintain the ETAG. Signed-off-by: Yehuda Sadeh <yehuda@inktank.com> Conflicts: src/rgw/rgw_rados.cc
This commit is contained in:
parent
25a9620a72
commit
214327ef6f
@ -1230,6 +1230,9 @@ int RGWRados::copy_obj(void *ctx,
|
||||
return ret;
|
||||
|
||||
if (replace_attrs) {
|
||||
if (!attrs[RGW_ATTR_ETAG].length())
|
||||
attrs[RGW_ATTR_ETAG] = attrset[RGW_ATTR_ETAG];
|
||||
|
||||
attrset = attrs;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user