Print this page
curzone reality check and teardown changes to use the RIGHT zone
*** 409,418 ****
--- 409,419 ----
rfs_climb_crossmnt(vnode_t **dvpp, struct exportinfo **exip, cred_t *cr)
{
struct exportinfo *exi;
vnode_t *dvp = *dvpp;
+ ASSERT3P((*exip)->exi_zone, ==, curzone);
ASSERT((dvp->v_flag & VROOT) || VN_IS_CURZONEROOT(dvp));
VN_HOLD(dvp);
dvp = untraverse(dvp);
exi = nfs_vptoexi(NULL, dvp, cr, NULL, NULL, FALSE);
*** 419,428 ****
--- 420,430 ----
if (exi == NULL) {
VN_RELE(dvp);
return (-1);
}
+ ASSERT3P(exi->exi_zone, ==, curzone);
exi_rele(*exip);
*exip = exi;
VN_RELE(*dvpp);
*dvpp = dvp;
*** 479,488 ****
--- 481,491 ----
return;
}
}
exi_hold(exi);
+ ASSERT3P(exi->exi_zone, ==, curzone);
/*
* Not allow lookup beyond root.
* If the filehandle matches a filehandle of the exi,
* then the ".." refers beyond the root of an exported filesystem.
*** 1310,1319 ****
--- 1313,1323 ----
cred_t *savecred;
int in_crit = 0;
caller_context_t ct;
nfs_srv_t *nsrv;
+ ASSERT3P(curzone, ==, ((exi == NULL) ? curzone : exi->exi_zone));
nsrv = zone_getspecific(rfs_zone_key, curzone);
if (!nsrv->write_async) {
rfs_write_sync(wa, ns, exi, req, cr, ro);
return;
}