Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 4860
b: refs/heads/master
c: 251c842
h: refs/heads/master
v: v3
  • Loading branch information
Jesper Juhl authored and Anton Altaparmakov committed May 5, 2005
1 parent 2ff81ba commit 46ae9e0
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 13 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 53d59aad9326199ef5749c97513db498309a057e
refs/heads/master: 251c8427c9c418674fc3c04a11de95dc3661b560
2 changes: 2 additions & 0 deletions trunk/fs/ntfs/ChangeLog
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,8 @@ ToDo/Notes:
- Modify ->readpage and ->writepage (fs/ntfs/aops.c) so they detect and
handle the case where an attribute is converted from resident to
non-resident by a concurrent file write.
- Remove checks for NULL before calling kfree() since kfree() does the
checking itself. (Jesper Juhl)

2.1.22 - Many bug and race fixes and error handling improvements.

Expand Down
12 changes: 4 additions & 8 deletions trunk/fs/ntfs/dir.c
Original file line number Diff line number Diff line change
Expand Up @@ -183,8 +183,7 @@ MFT_REF ntfs_lookup_inode_by_name(ntfs_inode *dir_ni, const ntfschar *uname,
name->len = 0;
*res = name;
} else {
if (name)
kfree(name);
kfree(name);
*res = NULL;
}
mref = le64_to_cpu(ie->data.dir.indexed_file);
Expand Down Expand Up @@ -444,8 +443,7 @@ MFT_REF ntfs_lookup_inode_by_name(ntfs_inode *dir_ni, const ntfschar *uname,
name->len = 0;
*res = name;
} else {
if (name)
kfree(name);
kfree(name);
*res = NULL;
}
mref = le64_to_cpu(ie->data.dir.indexed_file);
Expand Down Expand Up @@ -1462,10 +1460,8 @@ static int ntfs_readdir(struct file *filp, void *dirent, filldir_t filldir)
unlock_page(ia_page);
ntfs_unmap_page(ia_page);
}
if (ir)
kfree(ir);
if (name)
kfree(name);
kfree(ir);
kfree(name);
if (ctx)
ntfs_attr_put_search_ctx(ctx);
if (m)
Expand Down
3 changes: 1 addition & 2 deletions trunk/fs/ntfs/namei.c
Original file line number Diff line number Diff line change
Expand Up @@ -153,8 +153,7 @@ static struct dentry *ntfs_lookup(struct inode *dir_ino, struct dentry *dent,
ntfs_error(vol->sb, "ntfs_iget(0x%lx) failed with "
"error code %li.", dent_ino,
PTR_ERR(dent_inode));
if (name)
kfree(name);
kfree(name);
/* Return the error code. */
return (struct dentry *)dent_inode;
}
Expand Down
3 changes: 1 addition & 2 deletions trunk/fs/ntfs/super.c
Original file line number Diff line number Diff line change
Expand Up @@ -1193,8 +1193,7 @@ static BOOL load_and_init_quota(ntfs_volume *vol)
return FALSE;
}
/* We do not care for the type of match that was found. */
if (name)
kfree(name);
kfree(name);
/* Get the inode. */
tmp_ino = ntfs_iget(vol->sb, MREF(mref));
if (IS_ERR(tmp_ino) || is_bad_inode(tmp_ino)) {
Expand Down

0 comments on commit 46ae9e0

Please sign in to comment.