new_clu.flags = new_fid->flags;
if (!is_dir_empty(sb, &new_clu)) {
- ret = FFS_FILEEXIST;
+ ret = -EEXIST;
goto out;
}
}
clu_to_free.flags = fid->flags;
if (!is_dir_empty(sb, &clu_to_free)) {
- ret = FFS_FILEEXIST;
+ ret = -EEXIST;
goto out;
}
if (err) {
if (err == FFS_INVALIDPATH)
err = -EINVAL;
- else if (err == FFS_FILEEXIST)
+ else if (err == -EEXIST)
err = -EEXIST;
else if (err == -ENOSPC)
err = -ENOSPC;
if (err) {
if (err == FFS_INVALIDPATH)
err = -EINVAL;
- else if (err == FFS_FILEEXIST)
+ else if (err == -EEXIST)
err = -EEXIST;
else if (err == -ENOSPC)
err = -ENOSPC;
if (err) {
if (err == FFS_INVALIDPATH)
err = -EINVAL;
- else if (err == FFS_FILEEXIST)
+ else if (err == -EEXIST)
err = -EEXIST;
else if (err == -ENOSPC)
err = -ENOSPC;
if (err) {
if (err == FFS_INVALIDPATH)
err = -EINVAL;
- else if (err == FFS_FILEEXIST)
+ else if (err == -EEXIST)
err = -ENOTEMPTY;
else if (err == -ENOENT)
err = -ENOENT;
err = -EPERM;
else if (err == FFS_INVALIDPATH)
err = -EINVAL;
- else if (err == FFS_FILEEXIST)
+ else if (err == -EEXIST)
err = -EEXIST;
else if (err == -ENOENT)
err = -ENOENT;