summaryrefslogtreecommitdiff
path: root/source4/lib
diff options
context:
space:
mode:
Diffstat (limited to 'source4/lib')
-rw-r--r--source4/lib/util/data_blob.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/source4/lib/util/data_blob.c b/source4/lib/util/data_blob.c
index 7230aa9d99..e04bd65331 100644
--- a/source4/lib/util/data_blob.c
+++ b/source4/lib/util/data_blob.c
@@ -163,6 +163,7 @@ _PUBLIC_ char *data_blob_hex_string(TALLOC_CTX *mem_ctx, const DATA_BLOB *blob)
for (i = 0; i < blob->length; i++)
slprintf(&hex_string[i*2], 3, "%02X", blob->data[i]);
+ hex_string[(blob->length*2)] = '\0';
return hex_string;
}