summaryrefslogtreecommitdiff
path: root/lib/sqfs/id_table_read.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/sqfs/id_table_read.c')
-rw-r--r--lib/sqfs/id_table_read.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/sqfs/id_table_read.c b/lib/sqfs/id_table_read.c
index 6e1789d..58b0cf9 100644
--- a/lib/sqfs/id_table_read.c
+++ b/lib/sqfs/id_table_read.c
@@ -28,7 +28,7 @@ int id_table_read(id_table_t *tbl, int fd, sqfs_super_t *super,
return -1;
}
- tbl->ids = malloc(super->id_count * sizeof(uint32_t));
+ tbl->ids = calloc(super->id_count, sizeof(uint32_t));
if (tbl->ids == NULL) {
perror("reading ID table");
return -1;