STABLE14-darwin80-mkdir-error-leak-fix-20060215

avoid a potential refcount decrement "leak" (well, the opposite, really) when a mkdir fails


(cherry picked from commit 33d58440d1fa3938ff627e888537c367d06b1bf9)
This commit is contained in:
Chaskiel M Grundman 2006-02-15 07:02:21 +00:00 committed by Derrick Brashear
parent 9d1aabc7a5
commit d71224dabc

View File

@ -1430,8 +1430,10 @@ afs_vop_mkdir(ap)
error = afs_mkdir(VTOAFS(dvp), name, vap, &vcp, vop_cn_cred);
AFS_GUNLOCK();
if (error) {
#ifndef AFS_DARWIN80_ENV
VOP_ABORTOP(dvp, cnp);
vput(dvp);
#endif
DROPNAME();
return (error);
}