[PATCH] fsck.minix: fix zone_map memory allocation failure check

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Signed-off-by: Francesco Cosoleto <cosoleto@xxxxxxxxx>
---
 disk-utils/fsck.minix.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/disk-utils/fsck.minix.c b/disk-utils/fsck.minix.c
index ccbb7a9..95e3ecf 100644
--- a/disk-utils/fsck.minix.c
+++ b/disk-utils/fsck.minix.c
@@ -609,7 +609,7 @@ read_tables(void) {
 	if (!inode_map)
 		die(_("Unable to allocate buffer for inode map"));
 	zone_map = malloc(zmaps * MINIX_BLOCK_SIZE);
-	if (!inode_map)
+	if (!zone_map)
 		die(_("Unable to allocate buffer for zone map"));
 	inode_buffer = malloc(buffsz);
 	if (!inode_buffer)
-- 
1.7.3.4

--
To unsubscribe from this list: send the line "unsubscribe util-linux" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux