]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
Do not warn about lock-file option change when -X is used
authorAram Sargsyan <aram@isc.org>
Thu, 26 Oct 2023 12:28:25 +0000 (12:28 +0000)
committerAram Sargsyan <aram@isc.org>
Thu, 26 Oct 2023 13:12:57 +0000 (13:12 +0000)
When -X is used the 'lock-file' option change detection condition
is invalid, because it compares the 'lock-file' option's value to
the '-X' argument's value instead of the older 'lock-file' option
value (which was ignored because of '-X').

Don't warn about changing 'lock-file' option if '-X' is used.

(cherry picked from commit 41945b32d76c99e18c697d03ebc039091386667c)

bin/named/server.c

index 305a7d36b371d5c5692d05836da1d2fe81c8a9f8..cc874d0f203c0d0e14203c0b23b438c5829c6979 100644 (file)
@@ -8408,7 +8408,7 @@ check_lockfile(named_server_t *server, const cfg_obj_t *config,
 
        if (!first_time) {
                if (obj != NULL && cfg_obj_isstring(obj) &&
-                   server->lockfile != NULL &&
+                   server->lockfile != NULL && !named_g_forcelock &&
                    strcmp(cfg_obj_asstring(obj), server->lockfile) != 0)
                {
                        isc_log_write(named_g_lctx, NAMED_LOGCATEGORY_GENERAL,