The following pull request was submitted through Github.
It can be accessed and reviewed at: https://github.com/lxc/lxd/pull/3611

This e-mail was sent by the LXC bot, direct replies will not reach the author
unless they happen to be subscribed to this list.

=== Description (from pull-request) ===

From 9d4447465b86ef8d0233842947cef4ffe97d53b9 Mon Sep 17 00:00:00 2001
From: Alberto Donato <[email protected]>
Date: Mon, 31 Jul 2017 15:21:36 +0200
Subject: [PATCH] Log a warning for unknown config keys and don't crash.

Signed-off-by: Alberto Donato <[email protected]>
---
 lxd/daemon_config.go | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/lxd/daemon_config.go b/lxd/daemon_config.go
index 15c55a429..6e9a78085 100644
--- a/lxd/daemon_config.go
+++ b/lxd/daemon_config.go
@@ -210,7 +210,8 @@ func daemonConfigInit(db *sql.DB) error {
        for k, v := range dbValues {
                _, ok := daemonConfig[k]
                if !ok {
-                       logger.Error("Found invalid configuration key in 
database", log.Ctx{"key": k})
+                       logger.Warn("Found unknown configuration key in 
database", log.Ctx{"key": k})
+                       break
                }
 
                daemonConfig[k].currentValue = v
_______________________________________________
lxc-devel mailing list
[email protected]
http://lists.linuxcontainers.org/listinfo/lxc-devel

Reply via email to