mirror of
https://github.com/ceph/ceph
synced 2025-01-27 21:44:58 +00:00
mon/MonClient: make _sub_got behave if we "got" old stuff
Signed-off-by: Sage Weil <sage@redhat.com>
This commit is contained in:
parent
ca75e37a30
commit
57121dbe2c
@ -231,15 +231,19 @@ private:
|
||||
}
|
||||
void _sub_got(string what, version_t got) {
|
||||
if (sub_new.count(what)) {
|
||||
if (sub_new[what].flags & CEPH_SUBSCRIBE_ONETIME)
|
||||
sub_new.erase(what);
|
||||
else
|
||||
sub_new[what].start = got + 1;
|
||||
if (sub_new[what].start <= got) {
|
||||
if (sub_new[what].flags & CEPH_SUBSCRIBE_ONETIME)
|
||||
sub_new.erase(what);
|
||||
else
|
||||
sub_new[what].start = got + 1;
|
||||
}
|
||||
} else if (sub_sent.count(what)) {
|
||||
if (sub_sent[what].flags & CEPH_SUBSCRIBE_ONETIME)
|
||||
sub_sent.erase(what);
|
||||
else
|
||||
sub_sent[what].start = got + 1;
|
||||
if (sub_sent[what].start <= got) {
|
||||
if (sub_sent[what].flags & CEPH_SUBSCRIBE_ONETIME)
|
||||
sub_sent.erase(what);
|
||||
else
|
||||
sub_sent[what].start = got + 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
void _sub_unwant(string what) {
|
||||
|
Loading…
Reference in New Issue
Block a user