summaryrefslogtreecommitdiff
path: root/sbin/fsck_ext2fs/inode.c
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>2014-10-29 06:31:59 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>2014-10-29 06:31:59 +0000
commitea08ae354fb506b8f50db27ce28b5d9fe74646dc (patch)
tree2e9acf5e44a0f432626416c5996a171f0b0d1b4e /sbin/fsck_ext2fs/inode.c
parent7dcf75f73906f68fa97b39fbaa1cde496a4d70e3 (diff)
remove ugly return value casts
Diffstat (limited to 'sbin/fsck_ext2fs/inode.c')
-rw-r--r--sbin/fsck_ext2fs/inode.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/sbin/fsck_ext2fs/inode.c b/sbin/fsck_ext2fs/inode.c
index 142bf07aa92..9327388906e 100644
--- a/sbin/fsck_ext2fs/inode.c
+++ b/sbin/fsck_ext2fs/inode.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: inode.c,v 1.23 2014/10/08 16:28:12 deraadt Exp $ */
+/* $OpenBSD: inode.c,v 1.24 2014/10/29 06:31:58 deraadt Exp $ */
/* $NetBSD: inode.c,v 1.8 2000/01/28 16:01:46 bouyer Exp $ */
/*
@@ -398,8 +398,7 @@ resetinodebuf(void)
partialsize = inobufsize;
}
if (inodebuf == NULL &&
- (inodebuf = (struct ext2fs_dinode *)malloc((unsigned)inobufsize)) ==
- NULL)
+ (inodebuf = malloc((unsigned)inobufsize)) == NULL)
errexit("Cannot allocate space for inode buffer\n");
while (nextino < EXT2_ROOTINO)
(void)getnextinode(nextino);
@@ -431,8 +430,7 @@ cacheino(struct ext2fs_dinode *dp, ino_t inumber)
blks = howmany(inosize(dp), sblock.e2fs_bsize);
if (blks > NDADDR)
blks = NDADDR + NIADDR;
- inp = (struct inoinfo *)
- malloc(sizeof(*inp) + (blks - 1) * sizeof(daddr32_t));
+ inp = malloc(sizeof(*inp) + (blks - 1) * sizeof(daddr32_t));
if (inp == NULL)
return;
inpp = &inphead[inumber % numdirs];