- Fix #596: Bail out of unbound-control list_local_zones when ssl

write fails.


git-svn-id: file:///svn/unbound/trunk@3193 be551aaa-1e26-0410-a405-d3ace91eadb9
This commit is contained in:
Wouter Wijngaards 2014-07-15 14:42:57 +00:00
parent 1145890998
commit ae7049063c
2 changed files with 11 additions and 2 deletions

View file

@ -2088,8 +2088,13 @@ do_list_local_zones(SSL* ssl, struct worker* worker)
RBTREE_FOR(z, struct local_zone*, &zones->ztree) {
lock_rw_rdlock(&z->lock);
dname_str(z->name, buf);
(void)ssl_printf(ssl, "%s %s\n", buf,
local_zone_type2str(z->type));
if(!ssl_printf(ssl, "%s %s\n", buf,
local_zone_type2str(z->type))) {
/* failure to print */
lock_rw_unlock(&z->lock);
lock_rw_unlock(&zones->lock);
return;
}
lock_rw_unlock(&z->lock);
}
lock_rw_unlock(&zones->lock);

View file

@ -1,3 +1,7 @@
15 July 2014: Wouter
- Fix #596: Bail out of unbound-control list_local_zones when ssl
write fails.
13 July 2014: Wouter
- Configure tests if main can be linked to from getentropy compat.