X-Git-Url: https://git.distorted.org.uk/~mdw/adns/blobdiff_plain/ea1e31e326a99219a0a6edf28a75845b79b74893..32af6b2a02aa7e71b367b71a048bd2459e368c25:/src/transmit.c diff --git a/src/transmit.c b/src/transmit.c index ffab58b..d0b9d95 100644 --- a/src/transmit.c +++ b/src/transmit.c @@ -4,7 +4,7 @@ * - send queries */ /* - * This file is part of adns, which is Copyright (C) 1997, 1998 Ian Jackson + * This file is part of adns, which is Copyright (C) 1997-1999 Ian Jackson * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -179,7 +179,9 @@ void adns__query_tcp(adns_query qu, struct timeval now) { iov[0].iov_len= 2; iov[1].iov_base= qu->query_dgram; iov[1].iov_len= qu->query_dglen; + adns__sigpipe_protect(qu->ads); wr= writev(qu->ads->tcpsocket,iov,2); + adns__sigpipe_unprotect(qu->ads); if (wr < 0) { if (!(errno == EAGAIN || errno == EINTR || errno == ENOSPC || errno == ENOBUFS || errno == ENOMEM)) {