summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--hivex/hivex.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/hivex/hivex.c b/hivex/hivex.c
index b522ccf8..4fa3b301 100644
--- a/hivex/hivex.c
+++ b/hivex/hivex.c
@@ -271,6 +271,8 @@ hivex_open (const char *filename, int flags)
}
h->bitmap = calloc (1 + h->size / 32, 1);
+ if (h->bitmap == NULL)
+ goto error;
#if 0 /* Doesn't work. */
/* Header checksum. */