diff options
author | Laurent Bercot <ska-skaware@skarnet.org> | 2017-08-22 10:34:13 +0000 |
---|---|---|
committer | Laurent Bercot <ska-skaware@skarnet.org> | 2017-08-22 10:34:13 +0000 |
commit | 285054f4308819e7fcc1e69d2815efadabefca6a (patch) | |
tree | 0e9901b437bfe2e6431d89b03bd8f9ac7db30bd9 | |
parent | 5fd6a10bf8e59200da268901d0ba880485aa054f (diff) | |
download | s6-dns-285054f4308819e7fcc1e69d2815efadabefca6a.tar.xz |
Don't save errno around fd_close ; prepare for 2.2.0.1
-rw-r--r-- | COPYING | 2 | ||||
-rw-r--r-- | INSTALL | 8 | ||||
-rw-r--r-- | NEWS | 6 | ||||
-rw-r--r-- | doc/index.html | 4 | ||||
-rw-r--r-- | doc/upgrade.html | 6 | ||||
-rw-r--r-- | package/info | 2 | ||||
-rw-r--r-- | src/libs6dns/s6dns_engine.c | 12 |
7 files changed, 23 insertions, 17 deletions
@@ -1,4 +1,4 @@ -Copyright (c) 2011-2016 Laurent Bercot <ska-skaware@skarnet.org> +Copyright (c) 2011-2017 Laurent Bercot <ska-skaware@skarnet.org> Permission to use, copy, modify, and distribute this software for any purpose with or without fee is hereby granted, provided that the above @@ -6,7 +6,7 @@ Build Instructions - A POSIX-compliant C development environment - GNU make version 3.81 or later - - skalibs version 2.5.0.0 or later: http://skarnet.org/software/skalibs/ + - skalibs version 2.6.0.0 or later: http://skarnet.org/software/skalibs/ This software will run on any operating system that implements POSIX.1-2008, available at: @@ -22,6 +22,12 @@ POSIX.1-2008, available at: It will install the binaries in /bin and the static libraries in /usr/lib/s6-dns. + Please note that static libraries in /usr/lib/s6-dns *will not* +be found by a default linker invocation: you need -L/usr/lib/s6-dns. +Other skarnet.org software automatically handles that case if the +default configuration is used, but if you change the configuration, +remember to use the appropriate --with-lib configure option. + You can strip the binaries and libraries of their extra symbols via "make strip" before the "make install" phase. It will shave a few bytes off them. @@ -1,5 +1,11 @@ Changelog for s6-dns. +In 2.2.0.1 +---------- + + - Optimization release for skalibs-2.6.0.0. + + In 2.2.0.0 ---------- diff --git a/doc/index.html b/doc/index.html index 7793388..c83eac1 100644 --- a/doc/index.html +++ b/doc/index.html @@ -46,7 +46,7 @@ point in the future. <li> A POSIX-compliant system with a standard C development environment </li> <li> GNU make, version 3.81 or later </li> <li> <a href="//skarnet.org/software/skalibs/">skalibs</a> version -2.5.0.0 or later </li> +2.6.0.0 or later </li> </ul> <h3> Licensing </h3> @@ -59,7 +59,7 @@ point in the future. <h3> Download </h3> <ul> - <li> The current released version of s6-dns is <a href="s6-dns-2.2.0.0.tar.gz">2.2.0.0</a>. </li> + <li> The current released version of s6-dns is <a href="s6-dns-2.2.0.1.tar.gz">2.2.0.1</a>. </li> <li> Alternatively, you can checkout a copy of the <a href="//git.skarnet.org/cgi-bin/cgit.cgi/s6-dns/">s6-dns git repository</a>: diff --git a/doc/upgrade.html b/doc/upgrade.html index 69d1116..f74654d 100644 --- a/doc/upgrade.html +++ b/doc/upgrade.html @@ -18,6 +18,12 @@ <h1> What has changed in s6-dns </h1> +<h2> in 2.2.0.1 </h2> + +<ul> + <li> skalibs dependency bumped to 2.6.0.0. </li> +</ul> + <h2> in 2.2.0.0 </h2> <ul> diff --git a/package/info b/package/info index d29516e..ce41d09 100644 --- a/package/info +++ b/package/info @@ -1,4 +1,4 @@ package=s6-dns -version=2.2.0.0 +version=2.2.0.1 category=web package_macro_name=S6_DNS diff --git a/src/libs6dns/s6dns_engine.c b/src/libs6dns/s6dns_engine.c index 06cb218..26cb5f3 100644 --- a/src/libs6dns/s6dns_engine.c +++ b/src/libs6dns/s6dns_engine.c @@ -104,17 +104,13 @@ static int thisudp (s6dns_engine_t *dt, tain_t const *stamp) if (dt->fd < 0) return -1 ; if (!randombind(dt->fd, s6dns_ip46list_is6(&dt->servers, dt->curserver))) { - int e = errno ; fd_close(dt->fd) ; dt->fd = -1 ; - errno = e ; return -1 ; } if ((socketconnect46(dt->fd, s6dns_ip46list_ip(&dt->servers, dt->curserver), 53, s6dns_ip46list_is6(&dt->servers, dt->curserver)) < 0) && (errno != EINPROGRESS)) { - int e = errno ; fd_close(dt->fd) ; dt->fd = -1 ; - errno = e ; return 0 ; } tain_add(&dt->localdeadline, stamp, &tain_infinite_relative) ; @@ -135,17 +131,13 @@ static int thistcp (s6dns_engine_t *dt, tain_t const *stamp) if (dt->fd < 0) return -1 ; if (!randombind(dt->fd, s6dns_ip46list_is6(&dt->servers, dt->curserver))) { - int e = errno ; fd_close(dt->fd) ; dt->fd = -1 ; - errno = e ; return -1 ; } if ((socketconnect46(dt->fd, s6dns_ip46list_ip(&dt->servers, dt->curserver), 53, s6dns_ip46list_is6(&dt->servers, dt->curserver)) < 0) && (errno != EINPROGRESS)) { - int e = errno ; fd_close(dt->fd) ; dt->fd = -1 ; - errno = e ; return 0 ; } tain_addsec(&dt->localdeadline, stamp, 10) ; @@ -255,9 +247,7 @@ static int s6dns_engine_read_udp (s6dns_engine_t *dt, tain_t const *stamp) } if (!stralloc_copyb(&dt->sa, buf, r)) { - int e = errno ; fd_close(dt->fd) ; dt->fd = -1 ; - errno = e ; return 0 ; } dt->querylen = 0 ; @@ -314,9 +304,7 @@ void s6dns_engine_recycle (s6dns_engine_t *dt) memset(&dt->servers, 0, sizeof(s6dns_ip46list_t)) ; if (dt->fd >= 0) { - int e = errno ; fd_close(dt->fd) ; dt->fd = -1 ; - errno = e ; } dt->status = ECONNABORTED ; dt->flagstrict = dt->flagtcp = dt->flagconnecting = dt->flagreading = dt->flagwriting = 0 ; |