]> git.proxmox.com Git - mirror_lxc.git/commitdiff
When callback of one config line fail, we'd better give the exactly
authorQiang Huang <h.huangqiang@huawei.com>
Mon, 23 Sep 2013 16:23:27 +0000 (11:23 -0500)
committerSerge Hallyn <serge.hallyn@ubuntu.com>
Mon, 23 Sep 2013 16:23:27 +0000 (11:23 -0500)
info to help users locate the misconfig.

Signed-off-by: Qiang Huang <h.huangqiang@huawei.com>
Acked-by: Serge Hallyn <serge.hallyn@ubuntu.com>
Signed-off-by: Serge Hallyn <serge.hallyn@ubuntu.com>
src/lxc/parse.c

index 7875c8969ce772c4a6f35351e3beafb168c6cee8..5fca79ef09021fa9108e837a5c61872d1fa61db0 100644 (file)
@@ -101,8 +101,10 @@ int lxc_file_for_each_line(const char *file, lxc_file_cb callback, void *data)
 
        while (getline(&line, &len, f) != -1) {
                err = callback(line, data);
-               if (err)
+               if (err) {
+                       ERROR("Failed to parse config: %s", line);
                        break;
+               }
        }
 
        if (line)