We need to maintain the invariant that (dir_auth.first==whoami) == is_auth.
Signed-off-by: Sage Weil <sage@newdream.net>
++p) {
CDir *dir = p->first;
- if (dir->authority().first != who) continue;
+ if (dir->authority().first != who)
+ continue;
assert(!dir->is_auth());
// wake any waiters
assert(dir->get_cum_auth_pins() == 0);
// set ambiguous auth
- cache->adjust_subtree_auth(dir, dest, mds->get_nodeid());
+ cache->adjust_subtree_auth(dir, mds->get_nodeid(), dest);
// take away the popularity we're sending.
mds->balancer->subtract_export(dir, now);