{
long code;
#ifndef AFSIFS
- cm_scache_t *substRootp;
+ cm_scache_t *substRootp = NULL;
#endif
char * relativePath = ioctlp->inDatap;
CM_FLAG_CASEFOLD | CM_FLAG_FOLLOW,
userp, "", reqp, scpp);
- if (code)
- return code;
+ if (code) {
+ osi_Log1(afsd_logp,"cm_ParseIoctlPath code 0x%x", code);
+ return code;
+ }
#else /* AFSIFS */
if (relativePath[0] == relativePath[1] &&
relativePath[1] == '\\' &&
CM_FLAG_CASEFOLD | CM_FLAG_FOLLOW,
userp, sharePath, reqp, &substRootp);
free(sharePath);
- if (code)
+ if (code) {
+ osi_Log1(afsd_logp,"cm_ParseIoctlPath [1] code 0x%x", code);
return code;
+ }
code = cm_NameI(substRootp, p, CM_FLAG_CASEFOLD | CM_FLAG_FOLLOW,
userp, NULL, reqp, scpp);
- if (code)
+ if (code) {
+ osi_Log1(afsd_logp,"cm_ParseIoctlPath [2] code 0x%x", code);
return code;
+ }
} else {
/* otherwise, treat the name as a cellname mounted off the afs root.
* This requires that we reconstruct the shareName string with
code = cm_NameI(cm_data.rootSCachep, ioctlp->prefix->data,
CM_FLAG_CASEFOLD | CM_FLAG_FOLLOW,
userp, shareName, reqp, &substRootp);
- if (code)
+ if (code) {
+ osi_Log1(afsd_logp,"cm_ParseIoctlPath [3] code 0x%x", code);
return code;
+ }
code = cm_NameI(substRootp, p, CM_FLAG_CASEFOLD | CM_FLAG_FOLLOW,
userp, NULL, reqp, scpp);
- if (code)
+ if (code) {
+ cm_ReleaseSCache(substRootp);
+ osi_Log1(afsd_logp,"cm_ParseIoctlPath code [4] 0x%x", code);
return code;
+ }
}
} else {
code = cm_NameI(cm_data.rootSCachep, ioctlp->prefix->data,
CM_FLAG_CASEFOLD | CM_FLAG_FOLLOW,
userp, ioctlp->tidPathp, reqp, &substRootp);
- if (code)
+ if (code) {
+ osi_Log1(afsd_logp,"cm_ParseIoctlPath [6] code 0x%x", code);
return code;
+ }
code = cm_NameI(substRootp, relativePath, CM_FLAG_CASEFOLD | CM_FLAG_FOLLOW,
userp, NULL, reqp, scpp);
- if (code)
+ if (code) {
+ cm_ReleaseSCache(substRootp);
+ osi_Log1(afsd_logp,"cm_ParseIoctlPath [7] code 0x%x", code);
return code;
+ }
}
#endif /* AFSIFS */
/* This is usually nothing, but for StatMountPoint it is the file name. */
TranslateExtendedChars(ioctlp->inDatap);
+ if (substRootp)
+ cm_ReleaseSCache(substRootp);
+
/* and return success */
+ osi_Log1(afsd_logp,"cm_ParseIoctlPath [8] code 0x%x", code);
return 0;
}