From 3668b37b8b7769a577a17b429cb34431b4bcc47d Mon Sep 17 00:00:00 2001 From: Andreas Gustafsson Date: Mon, 17 Jul 2000 23:19:14 +0000 Subject: [PATCH] cleaner, but more invasive, fix to 335. --- bin/named/client.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/bin/named/client.c b/bin/named/client.c index 8ccca0c162..3df33b3bec 100644 --- a/bin/named/client.c +++ b/bin/named/client.c @@ -15,7 +15,7 @@ * SOFTWARE. */ -/* $Id: client.c,v 1.101 2000/07/17 18:43:30 bwelling Exp $ */ +/* $Id: client.c,v 1.102 2000/07/17 23:19:14 gson Exp $ */ #include @@ -488,6 +488,12 @@ ns_client_endrequest(ns_client_t *client) { if (client->recursionquota != NULL) isc_quota_detach(&client->recursionquota); + + /* + * Clear all client attributes that are specific to + * the request; that's all except the TCP flag. + */ + client->attributes &= NS_CLIENTATTR_TCP; } static void @@ -847,13 +853,9 @@ client_request(isc_task_t *task, isc_event_t *event) { if ((devent->attributes & ISC_SOCKEVENTATTR_PKTINFO) != 0) { client->attributes |= NS_CLIENTATTR_PKTINFO; client->pktinfo = devent->pktinfo; - } else { - client->attributes &= ~NS_CLIENTATTR_PKTINFO; } if ((devent->attributes & ISC_SOCKEVENTATTR_MULTICAST) != 0) client->attributes |= NS_CLIENTATTR_MULTICAST; - else - client->attributes &= ~NS_CLIENTATTR_MULTICAST; } else { INSIST(TCP_CLIENT(client)); REQUIRE(event->ev_type == DNS_EVENT_TCPMSG); @@ -1053,8 +1055,6 @@ client_request(isc_task_t *task, isc_event_t *event) { if (ra == ISC_TRUE) client->attributes |= NS_CLIENTATTR_RA; - else - client->attributes &= ~NS_CLIENTATTR_RA; /* * Dispatch the request.