mirror of
https://github.com/NLnetLabs/unbound.git
synced 2025-12-20 23:00:56 -05:00
Improved test, use empty buffer not random memory buffer.
git-svn-id: file:///svn/unbound/trunk@174 be551aaa-1e26-0410-a405-d3ace91eadb9
This commit is contained in:
parent
762af9f0a4
commit
09db7f94ed
1 changed files with 1 additions and 0 deletions
|
|
@ -125,6 +125,7 @@ static void
|
||||||
msgreply_test()
|
msgreply_test()
|
||||||
{
|
{
|
||||||
ldns_buffer* buff = ldns_buffer_new(65800);
|
ldns_buffer* buff = ldns_buffer_new(65800);
|
||||||
|
ldns_buffer_flip(buff);
|
||||||
unit_assert( query_dname_len(buff) == 0);
|
unit_assert( query_dname_len(buff) == 0);
|
||||||
unit_assert( query_dname_len(dname_to_buf(buff, ".")) == 1 );
|
unit_assert( query_dname_len(dname_to_buf(buff, ".")) == 1 );
|
||||||
unit_assert( query_dname_len(dname_to_buf(buff, "bla.foo.")) == 9 );
|
unit_assert( query_dname_len(dname_to_buf(buff, "bla.foo.")) == 9 );
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue