[systemd-commits] src/systemctl

Thomas H.P. Andersen phomes at kemper.freedesktop.org
Mon May 11 15:26:20 PDT 2015


 src/systemctl/systemctl.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit eacd8534257516e4fea049c7562f05349529c476
Author: Thomas Hindoe Paaboel Andersen <phomes at gmail.com>
Date:   Mon May 11 23:52:29 2015 +0200

    systemctl: fix check for template units
    
    A typo from 7410616c. We want to ignore EINVAL but only catch errors.

diff --git a/src/systemctl/systemctl.c b/src/systemctl/systemctl.c
index d48160e..1f18f9c 100644
--- a/src/systemctl/systemctl.c
+++ b/src/systemctl/systemctl.c
@@ -2339,7 +2339,7 @@ static int unit_find_paths(
                         _cleanup_free_ char *template = NULL;
 
                         r = unit_name_template(unit_name, &template);
-                        if (r != -EINVAL)
+                        if (r < 0 && r != -EINVAL)
                                 return log_error_errno(r, "Failed to determine template name: %m");
                         if (r >= 0) {
                                 r = unit_file_find_path(lp, template, &path);



More information about the systemd-commits mailing list