From 3b465d360059f3374f974c809762636afd66e083 Mon Sep 17 00:00:00 2001 From: Willem Toorop Date: Tue, 2 May 2017 14:29:47 +0200 Subject: [PATCH] Another small bug in str2wire function --- src/gldns/str2wire.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/gldns/str2wire.c b/src/gldns/str2wire.c index 89844f13..08388658 100644 --- a/src/gldns/str2wire.c +++ b/src/gldns/str2wire.c @@ -2018,6 +2018,6 @@ int gldns_str2wire_int16_data_buf(const char* str, uint8_t* rd, size_t* len) if(n < 0) return GLDNS_WIREPARSE_ERR_SYNTAX_B64; gldns_write_uint16(rd, (uint16_t)n); - *len = (size_t)n; + *len = ((size_t)n)+2; return GLDNS_WIREPARSE_ERR_OK; }