Don't display an error when the callback returns an error different from zero. A value greater than zero may means "stop". Let's the caller to check the error.
Signed-off-by: Daniel Lezcano <dlezc...@fr.ibm.com> --- src/lxc/parse.c | 4 +--- 1 files changed, 1 insertions(+), 3 deletions(-) diff --git a/src/lxc/parse.c b/src/lxc/parse.c index ee6b5de..10510c9 100644 --- a/src/lxc/parse.c +++ b/src/lxc/parse.c @@ -81,10 +81,8 @@ 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) { - ERROR("failed to process '%s'", line); + if (err) break; - } } if (line) -- 1.7.0.4 ------------------------------------------------------------------------------ Virtualization is moving to the mainstream and overtaking non-virtualized environment for deploying applications. Does it make network security easier or more difficult to achieve? Read this whitepaper to separate the two and get a better understanding. http://p.sf.net/sfu/hp-phase2-d2d _______________________________________________ Lxc-devel mailing list Lxc-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/lxc-devel