summaryrefslogtreecommitdiff
path: root/source4/lib/registry/regf.c
diff options
context:
space:
mode:
Diffstat (limited to 'source4/lib/registry/regf.c')
-rw-r--r--source4/lib/registry/regf.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/source4/lib/registry/regf.c b/source4/lib/registry/regf.c
index b6a586cf78..06476b940e 100644
--- a/source4/lib/registry/regf.c
+++ b/source4/lib/registry/regf.c
@@ -163,7 +163,9 @@ static DATA_BLOB hbin_alloc(struct regf_data *data, uint32_t size,
struct hbin_block *hbin = NULL;
unsigned int i;
- *offset = 0;
+ if (offset != NULL) {
+ *offset = 0;
+ }
if (size == 0)
return data_blob(NULL, 0);