]> git.ipfire.org Git - thirdparty/bind9.git/commit
Don't use an uninitialized link on an error path
authorAram Sargsyan <aram@isc.org>
Wed, 27 Sep 2023 11:22:43 +0000 (11:22 +0000)
committerAram Sargsyan <aram@isc.org>
Thu, 28 Sep 2023 08:14:05 +0000 (08:14 +0000)
commitfb7bbbd1be20632db28a928f49c4082373358b64
treeac29d4705414a720ef491531b982025b59cd16e1
parent98cbf4ebfc1f87e0cf9be49d8e4a587a50962eef
Don't use an uninitialized link on an error path

Move the block on the error path, where the link is checked, to a place
where it makes sense, to avoid accessing an unitialized link when
jumping to the 'cleanup_query' label from 4 different places. The link
is initialized only after those jumps happen.

In addition, initilize the link when creating the object, to avoid
similar errors.
lib/dns/resolver.c