]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
rt #5222: useing a wrong return type for isc_file_exists().
authorTatuya JINMEI 神明達哉 <jinmei@isc.org>
Sun, 23 Mar 2003 13:18:53 +0000 (13:18 +0000)
committerTatuya JINMEI 神明達哉 <jinmei@isc.org>
Sun, 23 Mar 2003 13:18:53 +0000 (13:18 +0000)
developer: marka
reviewer: jinmei

lib/dns/zone.c

index 1c08672f2854d80f888743f9a1fb5a9909cb7d01..f178e688ad09e5618b66cf418dcc0064b7820bb9 100644 (file)
@@ -15,7 +15,7 @@
  * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
  */
 
-/* $Id: zone.c,v 1.385 2003/02/26 23:28:59 marka Exp $ */
+/* $Id: zone.c,v 1.386 2003/03/23 13:18:53 jinmei Exp $ */
 
 #include <config.h>
 
@@ -1006,27 +1006,17 @@ zone_load(dns_zone_t *zone, unsigned int flags) {
        if ((zone->type == dns_zone_slave || zone->type == dns_zone_stub) &&
            (strcmp(zone->db_argv[0], "rbt") == 0 ||
             strcmp(zone->db_argv[0], "rbt64") == 0)) {
-               if (zone->masterfile != NULL) {
-                       result = isc_file_exists(zone->masterfile);
-               } else {
- start_timers:
+               if (zone->masterfile == NULL ||
+                   !isc_file_exists(zone->masterfile)) {
+                       if (zone->masterfile != NULL)
+                               dns_zone_log(zone, ISC_LOG_DEBUG(1),
+                                            "no master file");
+                       zone->refreshtime = now;
                        if (zone->task != NULL)
                                zone_settimer(zone, &now);
                        result = ISC_R_SUCCESS;
                        goto cleanup;
                }
-               if (result == ISC_R_FILENOTFOUND) {
-                       dns_zone_log(zone, ISC_LOG_DEBUG(1),
-                                    "no master file");
-                       goto start_timers;
-               } else if (result != ISC_R_SUCCESS) {
-                       dns_zone_log(zone, ISC_LOG_ERROR,
-                                    "loading master file %s: %s",
-                                    zone->masterfile,
-                                    dns_result_totext(result));
-                       result = ISC_R_SUCCESS;
-                       goto start_timers;
-               }
        }
 
        dns_zone_log(zone, ISC_LOG_DEBUG(1), "starting load");