parent
65de5d71a9
commit
426cddbb30
1 changed files with 6 additions and 6 deletions
|
@ -321,8 +321,11 @@ PUBLIC int fs_rename()
|
|||
old_ip = NULL;
|
||||
if (r == EENTERMOUNT) r = EXDEV; /* should this fail at all? */
|
||||
else if (r == ELEAVEMOUNT) r = EINVAL; /* rename on dot-dot */
|
||||
} else if (old_ip == NULL) {
|
||||
return(err_code);
|
||||
}
|
||||
|
||||
if (old_ip == NULL) {
|
||||
put_inode(old_dirp);
|
||||
return(r);
|
||||
}
|
||||
|
||||
/* Get new dir inode */
|
||||
|
@ -349,10 +352,7 @@ PUBLIC int fs_rename()
|
|||
r = EBUSY;
|
||||
}
|
||||
|
||||
if(old_ip != NULL)
|
||||
odir = ((old_ip->i_mode & I_TYPE) == I_DIRECTORY); /* TRUE iff dir */
|
||||
else
|
||||
odir = FALSE;
|
||||
|
||||
/* If it is ok, check for a variety of possible errors. */
|
||||
if(r == OK) {
|
||||
|
|
Loading…
Reference in a new issue