Commit 9f61f6b4 authored by Mark Andrews's avatar Mark Andrews
Browse files

initalize sigsize to zero; ATF_CHECK_EQ(sigsize, tsig.siglen);

parent be5a0eaa
......@@ -75,7 +75,7 @@ add_tsig(dst_context_t *tsigctx, dns_tsigkey_t *key, isc_buffer_t *target) {
isc_stdtime_t now;
unsigned char tsigbuf[1024];
unsigned int count;
unsigned int sigsize;
unsigned int sigsize = 0;
isc_boolean_t invalidate_ctx = ISC_FALSE;
memset(&tsig, 0, sizeof(tsig));
......@@ -110,6 +110,7 @@ add_tsig(dst_context_t *tsigctx, dns_tsigkey_t *key, isc_buffer_t *target) {
isc_buffer_init(&sigbuf, tsig.signature, sigsize);
CHECK(dst_context_sign(tsigctx, &sigbuf));
tsig.siglen = isc_buffer_usedlength(&sigbuf);
ATF_CHECK_EQ(sigsize, tsig.siglen);
CHECK(isc_buffer_allocate(mctx, &dynbuf, 512));
CHECK(dns_rdata_fromstruct(&rdata, dns_rdataclass_any,
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment