It's ok to run ConnMann without a configuration file, so don't print an
error message when this happens.
---
 src/main.c |    6 +++++-
 1 files changed, 5 insertions(+), 1 deletions(-)

diff --git a/src/main.c b/src/main.c
index 0f96d6c..bb08e40 100644
--- a/src/main.c
+++ b/src/main.c
@@ -57,7 +57,11 @@ static GKeyFile *load_config(const char *file)
        g_key_file_set_list_separator(keyfile, ',');
 
        if (!g_key_file_load_from_file(keyfile, file, 0, &err)) {
-               connman_error("Parsing %s failed: %s", file, err->message);
+               if (err->code != G_FILE_ERROR_NOENT) {
+                       connman_error("Parsing %s failed: %s", file,
+                                                               err->message);
+               }
+
                g_error_free(err);
                g_key_file_free(keyfile);
                return NULL;
-- 
1.7.5.2

_______________________________________________
connman mailing list
connman@connman.net
http://lists.connman.net/listinfo/connman

Reply via email to