mirror of
https://github.com/ceph/ceph
synced 2025-03-19 08:57:29 +00:00
objecter: normalize oloc.key
If oloc.key == oid, clear it. Users can set it to the oid or leave it blank; they are equivalent. Signed-off-by: Sage Weil <sage@newdream.net>
This commit is contained in:
parent
a3316f4479
commit
c4b51e30bb
@ -133,6 +133,8 @@ tid_t Objecter::linger(const object_t& oid, const object_locator_t& oloc,
|
||||
LingerOp *info = new LingerOp;
|
||||
info->oid = oid;
|
||||
info->oloc = oloc;
|
||||
if (info->oloc.key == oid)
|
||||
info->oloc.key.clear();
|
||||
info->snap = snap;
|
||||
info->flags = flags;
|
||||
info->ops = op.ops;
|
||||
|
@ -391,6 +391,9 @@ public:
|
||||
tid(0), attempts(0),
|
||||
paused(false), objver(ov), reply_epoch(NULL) {
|
||||
ops.swap(op);
|
||||
|
||||
if (oloc.key == o)
|
||||
oloc.key.clear();
|
||||
}
|
||||
|
||||
bool operator<(const Op& other) const {
|
||||
|
Loading…
Reference in New Issue
Block a user