]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
1706. [bug] 'rndc stop' failed to cause zones to be flushed
authorMark Andrews <marka@isc.org>
Fri, 27 Aug 2004 12:28:10 +0000 (12:28 +0000)
committerMark Andrews <marka@isc.org>
Fri, 27 Aug 2004 12:28:10 +0000 (12:28 +0000)
                        sometimes. [RT #12328]

CHANGES
lib/dns/zone.c

diff --git a/CHANGES b/CHANGES
index 6c7870f173accdde6710efb6e6b34a27672f75e9..9816750ebbe74d52a9c16ea699912ec9b83eb2a1 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -1,6 +1,7 @@
 1707.  [contrib]       sdb/ldap updated to version 1.0-beta.
 
-1706.  [placeholder]   rt12328
+1706.  [bug]           'rndc stop' failed to cause zones to be flushed
+                       sometimes. [RT #12328]
 
 1705.  [placeholder]   rt12327
 
index fe1d263f34d28b4a5b5ca615b7c96f06efbc14fe..4f1da9fa9a5464f590cfafc0d33638a237df519b 100644 (file)
@@ -15,7 +15,7 @@
  * PERFORMANCE OF THIS SOFTWARE.
  */
 
-/* $Id: zone.c,v 1.417 2004/07/29 00:17:06 marka Exp $ */
+/* $Id: zone.c,v 1.418 2004/08/27 12:28:10 marka Exp $ */
 
 #include <config.h>
 
@@ -4260,14 +4260,17 @@ zone_shutdown(isc_task_t *task, isc_event_t *event) {
        if (zone->readio != NULL)
                zonemgr_cancelio(zone->readio);
 
-       if (zone->writeio != NULL)
-               zonemgr_cancelio(zone->writeio);
-
        if (zone->lctx != NULL)
                dns_loadctx_cancel(zone->lctx);
 
-       if (zone->dctx != NULL)
-               dns_dumpctx_cancel(zone->dctx);
+       if (!DNS_ZONE_FLAG(zone, DNS_ZONEFLG_FLUSH) ||
+           !DNS_ZONE_FLAG(zone, DNS_ZONEFLG_DUMPING)) {
+               if (zone->writeio != NULL)
+                       zonemgr_cancelio(zone->writeio);
+
+               if (zone->dctx != NULL) 
+                       dns_dumpctx_cancel(zone->dctx);
+       }
 
        notify_cancel(zone);