chiark / gitweb /
core: output unit status output strings to console, only if we actually are changing...
[elogind.git] / src / core / load-fragment.c
index eea415883b53ada8ccd0456c8ff90719c71321e0..98794bfafbbf497e8df21946efbd04cbc0eaf564 100644 (file)
@@ -589,7 +589,8 @@ int config_parse_exec(const char *unit,
                 }
 
         found:
-                n = new(char*, k + !separate_argv0);
+                /* If separate_argv0, we'll move first element to path variable */
+                n = new(char*, MAX(k + !separate_argv0, 1u));
                 if (!n)
                         return log_oom();
 
@@ -2297,7 +2298,7 @@ int config_parse_documentation(const char *unit,
 
         for (a = b = u->documentation; a && *a; a++) {
 
-                if (is_valid_documentation_url(*a))
+                if (documentation_url_is_valid(*a))
                         *(b++) = *a;
                 else {
                         log_syntax(unit, LOG_ERR, filename, line, EINVAL,