Another small bug in str2wire function

This commit is contained in:
Willem Toorop 2017-05-02 14:29:47 +02:00
parent d1d95f4955
commit 3b465d3600
1 changed files with 1 additions and 1 deletions

View File

@ -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;
}