Commit 87c35578 authored by Jon Severinsson's avatar Jon Severinsson
Browse files

Add v208-stable patch series.

This commit was created using the following commands and then fixing up debian/patches/series manually.
$ git config diff.renames false
$ git rebase --onto debian/208-5 v208 stable/v208-stable
$ git checkout -b patch-queue/experimental HEAD
$ gbp-pq export --no-patch-numbers
$ git add --ignore-removal debian/patches/
parent dbde4e32
systemd (208-6) UNRELEASED; urgency=medium
* Add v208-stable patch series.
-- Jon Severinsson <jon@severinsson.net> Sun, 06 Jul 2014 18:00:00 +0200
systemd (208-5) experimental; urgency=medium
* Merge changes from unstable branch.
......
From: Scott Thrasher <scott.thrasher@gmail.com>
Date: Wed, 26 Mar 2014 18:48:13 -0700
Subject: Add hwdb entry for Samsung Series 7 Ultra
(cherry picked from commit 15f392394e75ffb7f318920008fd1bbe4e82b488)
(cherry picked from commit cc76be2f760478eb32b9645ba6cb84cc1b791a52)
---
hwdb/60-keyboard.hwdb | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/hwdb/60-keyboard.hwdb b/hwdb/60-keyboard.hwdb
index f9084e4..fdab827 100644
--- a/hwdb/60-keyboard.hwdb
+++ b/hwdb/60-keyboard.hwdb
@@ -921,6 +921,14 @@ keyboard:dmi:bvn*:bvr*:bd*:svn[sS][aA][mM][sS][uU][nN][gG]*:pn*90X3A*:pvr*
KEYBOARD_KEY_96=!kbdillumup # Fn+F8 keyboard backlight up
KEYBOARD_KEY_d5=!wlan # Fn+F12 Wi-Fi toggle
+# Series 7 Ultra
+keyboard:dmi:bvn*:bvr*:bd*:svn[sS][aA][mM][sS][uU][nN][gG]*:pn*7[34]0U3E*:pvr*
+ KEYBOARD_KEY_ce=!prog1 # Fn+F1 launch settings
+ KEYBOARD_KEY_97=!kbdillumdown # Fn+F9 keyboard backlight down
+ KEYBOARD_KEY_96=!kbdillumup # Fn+F10 keyboard backlight up
+ KEYBOARD_KEY_b3=!prog3 # Fn+F11 fan/cooling mode changer
+ KEYBOARD_KEY_d5=!wlan # Fn+F12 wlan/airplane switch
+
# SQ1US
keyboard:dmi:bvn*:bvr*:bd*:svn[sS][aA][mM][sS][uU][nN][gG]*:pnSQ1US:pvr*
KEYBOARD_KEY_d4=menu
From: Harald Hoyer <harald@redhat.com>
Date: Thu, 6 Mar 2014 16:35:02 +0100
Subject: Add strappenda3
(cherry picked from commit f39d4a08e746e703d562076a0f622eb91dbdcd3e)
For strappenda3, and it seems a good fix in general.
(cherry picked from commit 4f0b9b433473d4f2b24675253064fd098d21e5a6)
Conflicts:
src/systemctl/systemctl.c
---
src/shared/util.h | 13 +++++++++++++
1 file changed, 13 insertions(+)
diff --git a/src/shared/util.h b/src/shared/util.h
index 20d81e5..3f97663 100644
--- a/src/shared/util.h
+++ b/src/shared/util.h
@@ -728,6 +728,19 @@ int unlink_noerrno(const char *path);
_c_; \
})
+#define strappenda3(a, b, c) \
+ ({ \
+ const char *_a_ = (a), *_b_ = (b), *_c_ = (c); \
+ char *_d_; \
+ size_t _x_, _y_, _z_; \
+ _x_ = strlen(_a_); \
+ _y_ = strlen(_b_); \
+ _z_ = strlen(_c_); \
+ _d_ = alloca(_x_ + _y_ + _z_ + 1); \
+ strcpy(stpcpy(stpcpy(_d_, _a_), _b_), _c_); \
+ _d_; \
+ })
+
#define procfs_file_alloca(pid, field) \
({ \
pid_t _pid_ = (pid); \
From: Bastien Nocera <hadess@hadess.net>
Date: Fri, 11 Oct 2013 09:45:32 +0200
Subject: Add support for saving/restoring keyboard backlights
Piggy-backing on the display backlight code, this saves and restores
keyboard backlights on supported devices.
The detection code matches that of UPower:
http://cgit.freedesktop.org/upower/tree/src/up-kbd-backlight.c#n173
https://bugs.freedesktop.org/show_bug.cgi?id=70367
[tomegun: also work for devices named "{smc,samsung,asus}::kbd_backlight"]
Conflicts:
rules/99-systemd.rules.in
---
rules/99-systemd.rules.in | 4 +++-
src/backlight/backlight.c | 7 +++++--
2 files changed, 8 insertions(+), 3 deletions(-)
diff --git a/rules/99-systemd.rules.in b/rules/99-systemd.rules.in
index 307f18f..a00ffed 100644
--- a/rules/99-systemd.rules.in
+++ b/rules/99-systemd.rules.in
@@ -51,9 +51,11 @@ SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device", ENV{ID_USB_INTERFACES}=="*:0701??:
ACTION=="add", SUBSYSTEM=="net", KERNEL!="lo", RUN+="@rootlibexecdir@/systemd-sysctl --prefix=/proc/sys/net/ipv4/conf/$name --prefix=/proc/sys/net/ipv4/neigh/$name --prefix=/proc/sys/net/ipv6/conf/$name --prefix=/proc/sys/net/ipv6/neigh/$name"
-# Pull in backlight save/restore for all firmware backlight devices
+# Pull in backlight save/restore for all firmware backlight devices,
+# and keyboard backlights
SUBSYSTEM=="backlight", ATTR{type}=="firmware", TAG+="systemd", ENV{SYSTEMD_WANTS}+="systemd-backlight@$name.service"
+SUBSYSTEM=="leds", KERNEL=="*kbd_backlight", TAG+="systemd", ENV{SYSTEMD_WANTS}+="systemd-backlight@$name.service"
# Asynchronously mount file systems implemented by these modules as
# soon as they are loaded.
diff --git a/src/backlight/backlight.c b/src/backlight/backlight.c
index 9b2eada..f22deed 100644
--- a/src/backlight/backlight.c
+++ b/src/backlight/backlight.c
@@ -56,9 +56,11 @@ int main(int argc, char *argv[]) {
errno = 0;
device = udev_device_new_from_subsystem_sysname(udev, "backlight", argv[2]);
+ if (!device)
+ device = udev_device_new_from_subsystem_sysname(udev, "leds", argv[2]);
if (!device) {
if (errno != 0) {
- log_error("Failed to get backlight device: %m");
+ log_error("Failed to get backlight device '%s': %m", argv[2]);
r = -errno;
} else
r = log_oom();
@@ -66,7 +68,8 @@ int main(int argc, char *argv[]) {
goto finish;
}
- if (!streq_ptr(udev_device_get_subsystem(device), "backlight")) {
+ if (!streq_ptr(udev_device_get_subsystem(device), "backlight") &&
+ !streq_ptr(udev_device_get_subsystem(device), "leds")) {
log_error("Not a backlight device: %s", argv[2]);
r = -ENODEV;
goto finish;
From: =?utf-8?q?Zbigniew_J=C4=99drzejewski-Szmek?= <zbyszek@in.waw.pl>
Date: Sun, 2 Mar 2014 00:05:16 -0500
Subject: Allow fractional parts in disk sizes
It seems natural to be able to say SystemMaxUsage=1.5G.
https://bugzilla.redhat.com/show_bug.cgi?id=1047568
(cherry picked from commit 9480794b277b5ce33e467578ed669996df576bb9)
Conflicts:
src/test/test-util.c
---
src/shared/util.c | 24 ++++++++++++++++++++++--
1 file changed, 22 insertions(+), 2 deletions(-)
diff --git a/src/shared/util.c b/src/shared/util.c
index 7500779..e754747 100644
--- a/src/shared/util.c
+++ b/src/shared/util.c
@@ -2285,6 +2285,8 @@ int parse_bytes(const char *t, off_t *bytes) {
p = t;
do {
long long l;
+ unsigned long long l2;
+ double frac = 0;
char *e;
unsigned i;
@@ -2300,14 +2302,32 @@ int parse_bytes(const char *t, off_t *bytes) {
if (e == p)
return -EINVAL;
+ if (*e == '.') {
+ e++;
+ if (*e >= '0' && *e <= '9') {
+ char *e2;
+
+ /* strotoull itself would accept space/+/- */
+ l2 = strtoull(e, &e2, 10);
+
+ if (errno == ERANGE)
+ return -errno;
+
+ /* Ignore failure. E.g. 10.M is valid */
+ frac = l2;
+ for (; e < e2; e++)
+ frac /= 10;
+ }
+ }
+
e += strspn(e, WHITESPACE);
for (i = 0; i < ELEMENTSOF(table); i++)
if (startswith(e, table[i].suffix)) {
unsigned long long tmp;
- if ((unsigned long long) l > ULLONG_MAX / table[i].factor)
+ if ((unsigned long long) l + (frac > 0) > ULLONG_MAX / table[i].factor)
return -ERANGE;
- tmp = l * table[i].factor;
+ tmp = l * table[i].factor + (unsigned long long) (frac * table[i].factor);
if (tmp > ULLONG_MAX - r)
return -ERANGE;
From: Oleksii Shevchuk <alxchk@gmail.com>
Date: Mon, 4 Nov 2013 18:47:43 +0200
Subject: Configurable Timeouts/Restarts default values
https://bugs.freedesktop.org/show_bug.cgi?id=71132
Patch adds DefaultTimeoutStartSec, DefaultTimeoutStopSec, DefaultRestartSec
configuration options to manager configuration file.
---
man/systemd-system.conf.xml | 24 +++++++++++++++++++++++-
man/systemd.mount.xml | 4 ++--
man/systemd.service.xml | 6 ++++--
man/systemd.socket.xml | 4 ++--
man/systemd.swap.xml | 4 ++--
src/core/device.c | 2 +-
src/core/main.c | 9 +++++++++
src/core/manager.h | 3 +++
src/core/mount.c | 2 +-
src/core/scope.c | 2 +-
src/core/service.c | 6 +++---
src/core/socket.c | 2 +-
src/core/swap.c | 2 +-
src/core/system.conf | 3 +++
src/core/user.conf | 3 +++
15 files changed, 59 insertions(+), 17 deletions(-)
diff --git a/man/systemd-system.conf.xml b/man/systemd-system.conf.xml
index e8cf8a9..c1f2648 100644
--- a/man/systemd-system.conf.xml
+++ b/man/systemd-system.conf.xml
@@ -61,7 +61,6 @@
otherwise <filename>user.conf</filename>. These
configuration files contain a few settings controlling
basic manager operations.</para>
-
</refsect1>
<refsect1>
@@ -95,6 +94,29 @@
</varlistentry>
<varlistentry>
+ <term><varname>DefaultTimeoutStartSec=</varname></term>
+ <term><varname>DefaultTimeoutStopSec=</varname></term>
+ <term><varname>DefaultRestartSec=</varname></term>
+
+ <listitem><para>Configures the default
+ time-outs for starting and stopping of
+ units, as well as the default time to
+ sleep between automatic restarts of a
+ units, as configured per-unit in
+ <varname>TimeoutStartSec=</varname>,
+ <varname>TimeoutStopSec=</varname> and
+ <varname>RestartSec=</varname> (for
+ service units see
+ <citerefentry><refentrytitle>systemd.service</refentrytitle><manvolnum>5</manvolnum></citerefentry>
+ for details on the per-unit
+ settings). For non-service units
+ <varname>DefaultTimeoutStartSec=</varname>
+ sets the default
+ <varname>TimeoutSec=</varname> value.
+ </para></listitem>
+ </varlistentry>
+
+ <varlistentry>
<term><varname>CPUAffinity=</varname></term>
<listitem><para>Configures the initial
diff --git a/man/systemd.mount.xml b/man/systemd.mount.xml
index 48af1ca..71a5736 100644
--- a/man/systemd.mount.xml
+++ b/man/systemd.mount.xml
@@ -260,8 +260,8 @@
Takes a unit-less value in seconds, or
a time span value such as "5min
20s". Pass 0 to disable the timeout
- logic. Defaults to
- 90s.</para></listitem>
+ logic. Default value is setted up in manager configuration
+ file via <term><varname>DefaultTimeoutStart=</varname></term>.</para></listitem>
</varlistentry>
</variablelist>
diff --git a/man/systemd.service.xml b/man/systemd.service.xml
index 5e1ddf7..df04048 100644
--- a/man/systemd.service.xml
+++ b/man/systemd.service.xml
@@ -524,7 +524,8 @@
Takes a unit-less value in seconds, or a
time span value such as "5min
20s". Pass 0 to disable the timeout
- logic. Defaults to 90s, except when
+ logic. Defaults to <varname>TimeoutStartSec=</varname> in
+ manager configuration file, except when
<varname>Type=oneshot</varname> is
used in which case the timeout
is disabled by default.
@@ -545,7 +546,8 @@
Takes a unit-less value in seconds, or a
time span value such as "5min
20s". Pass 0 to disable the timeout
- logic. Defaults to 90s.
+ logic. Defaults to <varname>TimeoutStartSec=</varname> in
+ manager configuration file.
</para></listitem>
</varlistentry>
diff --git a/man/systemd.socket.xml b/man/systemd.socket.xml
index 8c88d9f..1c78562 100644
--- a/man/systemd.socket.xml
+++ b/man/systemd.socket.xml
@@ -679,8 +679,8 @@
Takes a unit-less value in seconds, or
a time span value such as "5min
20s". Pass 0 to disable the timeout
- logic. Defaults to
- 90s.</para></listitem>
+ logic. Defaults to <varname>TimeoutStartSec=</varname> in
+ manager configuration file.</para></listitem>
</varlistentry>
<varlistentry>
diff --git a/man/systemd.swap.xml b/man/systemd.swap.xml
index 813ae6c..13f6c84 100644
--- a/man/systemd.swap.xml
+++ b/man/systemd.swap.xml
@@ -186,8 +186,8 @@
Takes a unit-less value in seconds, or
a time span value such as "5min
20s". Pass 0 to disable the timeout
- logic. Defaults to
- 90s.</para></listitem>
+ logic. Defaults to <varname>TimeoutStartSec=</varname> in
+ manager configuration file.</para></listitem>
</varlistentry>
</variablelist>
diff --git a/src/core/device.c b/src/core/device.c
index 9fca82a..5397bd6 100644
--- a/src/core/device.c
+++ b/src/core/device.c
@@ -70,7 +70,7 @@ static void device_init(Unit *u) {
* indefinitely for plugged in devices, something which cannot
* happen for the other units since their operations time out
* anyway. */
- UNIT(d)->job_timeout = DEFAULT_TIMEOUT_USEC;
+ UNIT(d)->job_timeout = u->manager->default_timeout_start_usec;
UNIT(d)->ignore_on_isolate = true;
UNIT(d)->ignore_on_snapshot = true;
diff --git a/src/core/main.c b/src/core/main.c
index fe291f8..937994c 100644
--- a/src/core/main.c
+++ b/src/core/main.c
@@ -90,6 +90,9 @@ static bool arg_switched_root = false;
static char ***arg_join_controllers = NULL;
static ExecOutput arg_default_std_output = EXEC_OUTPUT_JOURNAL;
static ExecOutput arg_default_std_error = EXEC_OUTPUT_INHERIT;
+static usec_t arg_default_restart_usec = DEFAULT_RESTART_USEC;
+static usec_t arg_default_timeout_start_usec = DEFAULT_TIMEOUT_USEC;
+static usec_t arg_default_timeout_stop_usec = DEFAULT_TIMEOUT_USEC;
static usec_t arg_runtime_watchdog = 0;
static usec_t arg_shutdown_watchdog = 10 * USEC_PER_MINUTE;
static char **arg_default_environment = NULL;
@@ -636,6 +639,9 @@ static int parse_config_file(void) {
{ "Manager", "CPUAffinity", config_parse_cpu_affinity2, 0, NULL },
{ "Manager", "DefaultStandardOutput", config_parse_output, 0, &arg_default_std_output },
{ "Manager", "DefaultStandardError", config_parse_output, 0, &arg_default_std_error },
+ { "Manager", "DefaultTimeoutStartSec", config_parse_sec, 0, &arg_default_timeout_start_usec },
+ { "Manager", "DefaultTimeoutStopSec", config_parse_sec, 0, &arg_default_timeout_stop_usec },
+ { "Manager", "DefaultRestartSec", config_parse_sec, 0, &arg_default_restart_usec },
{ "Manager", "JoinControllers", config_parse_join_controllers, 0, &arg_join_controllers },
{ "Manager", "RuntimeWatchdogSec", config_parse_sec, 0, &arg_runtime_watchdog },
{ "Manager", "ShutdownWatchdogSec", config_parse_sec, 0, &arg_shutdown_watchdog },
@@ -1542,6 +1548,9 @@ int main(int argc, char *argv[]) {
m->confirm_spawn = arg_confirm_spawn;
m->default_std_output = arg_default_std_output;
m->default_std_error = arg_default_std_error;
+ m->default_restart_usec = arg_default_restart_usec;
+ m->default_timeout_start_usec = arg_default_timeout_start_usec;
+ m->default_timeout_stop_usec = arg_default_timeout_stop_usec;
m->runtime_watchdog = arg_runtime_watchdog;
m->shutdown_watchdog = arg_shutdown_watchdog;
m->userspace_timestamp = userspace_timestamp;
diff --git a/src/core/manager.h b/src/core/manager.h
index a3049b5..e74c609 100644
--- a/src/core/manager.h
+++ b/src/core/manager.h
@@ -230,6 +230,9 @@ struct Manager {
ExecOutput default_std_output, default_std_error;
+ usec_t default_restart_usec, default_timeout_start_usec,
+ default_timeout_stop_usec;
+
struct rlimit *rlimit[RLIMIT_NLIMITS];
/* non-zero if we are reloading or reexecuting, */
diff --git a/src/core/mount.c b/src/core/mount.c
index 70cd372..c0445a6 100644
--- a/src/core/mount.c
+++ b/src/core/mount.c
@@ -131,7 +131,7 @@ static void mount_init(Unit *u) {
assert(u);
assert(u->load_state == UNIT_STUB);
- m->timeout_usec = DEFAULT_TIMEOUT_USEC;
+ m->timeout_usec = u->manager->default_timeout_start_usec;
m->directory_mode = 0755;
exec_context_init(&m->exec_context);
diff --git a/src/core/scope.c b/src/core/scope.c
index 50e5dba..41da3b9 100644
--- a/src/core/scope.c
+++ b/src/core/scope.c
@@ -46,7 +46,7 @@ static void scope_init(Unit *u) {
assert(u);
assert(u->load_state == UNIT_STUB);
- s->timeout_stop_usec = DEFAULT_TIMEOUT_USEC;
+ s->timeout_stop_usec = u->manager->default_timeout_stop_usec;
watch_init(&s->timer_watch);
diff --git a/src/core/service.c b/src/core/service.c
index 96ed2d3..e81aa1f 100644
--- a/src/core/service.c
+++ b/src/core/service.c
@@ -124,9 +124,9 @@ static void service_init(Unit *u) {
assert(u);
assert(u->load_state == UNIT_STUB);
- s->timeout_start_usec = DEFAULT_TIMEOUT_USEC;
- s->timeout_stop_usec = DEFAULT_TIMEOUT_USEC;
- s->restart_usec = DEFAULT_RESTART_USEC;
+ s->timeout_start_usec = u->manager->default_timeout_start_usec;
+ s->timeout_stop_usec = u->manager->default_timeout_stop_usec;
+ s->restart_usec = u->manager->default_restart_usec;
s->type = _SERVICE_TYPE_INVALID;
watch_init(&s->watchdog_watch);
diff --git a/src/core/socket.c b/src/core/socket.c
index 6c0ac1a..d368f7e 100644
--- a/src/core/socket.c
+++ b/src/core/socket.c
@@ -73,7 +73,7 @@ static void socket_init(Unit *u) {
assert(u->load_state == UNIT_STUB);
s->backlog = SOMAXCONN;
- s->timeout_usec = DEFAULT_TIMEOUT_USEC;
+ s->timeout_usec = u->manager->default_timeout_start_usec;
s->directory_mode = 0755;
s->socket_mode = 0666;
diff --git a/src/core/swap.c b/src/core/swap.c
index a68ab7c..147f710 100644
--- a/src/core/swap.c
+++ b/src/core/swap.c
@@ -86,7 +86,7 @@ static void swap_init(Unit *u) {
assert(s);
assert(UNIT(s)->load_state == UNIT_STUB);
- s->timeout_usec = DEFAULT_TIMEOUT_USEC;
+ s->timeout_usec = u->manager->default_timeout_start_usec;
exec_context_init(&s->exec_context);
s->exec_context.std_output = u->manager->default_std_output;
diff --git a/src/core/system.conf b/src/core/system.conf
index 7b03c87..3c6cc03 100644
--- a/src/core/system.conf
+++ b/src/core/system.conf
@@ -24,6 +24,9 @@
#ShutdownWatchdogSec=10min
#CapabilityBoundingSet=
#TimerSlackNSec=
+#DefaultTimeoutStartSec=90s
+#DefaultTimeoutStopSec=90s
+#DefaultRestartSec=100ms
#DefaultEnvironment=
#DefaultLimitCPU=
#DefaultLimitFSIZE=
diff --git a/src/core/user.conf b/src/core/user.conf
index 4a0129a..b030701 100644
--- a/src/core/user.conf
+++ b/src/core/user.conf
@@ -14,3 +14,6 @@
#LogLocation=no
#DefaultStandardOutput=inherit
#DefaultStandardError=inherit
+#DefaultTimeoutStartSec=90s
+#DefaultTimeoutStopSec=90s
+#DefaultRestartSec=100ms
From: Shawn Landden <shawn@churchofgit.com>
Date: Fri, 20 Dec 2013 15:35:38 -0800
Subject: DEFAULT_PATH_SPLIT_USR macro
(cherry picked from commit e10a55fd72b5246cec1bbd09135d544db32e0414)
---
src/nspawn/nspawn.c | 2 +-
src/shared/path-util.h | 7 +++++--
2 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/src/nspawn/nspawn.c b/src/nspawn/nspawn.c
index 618f9c3..cafc306 100644
--- a/src/nspawn/nspawn.c
+++ b/src/nspawn/nspawn.c
@@ -1227,7 +1227,7 @@ int main(int argc, char *argv[]) {
gid_t gid = (gid_t) -1;
unsigned n_env = 2;
const char *envp[] = {
- "PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin",
+ "PATH=" DEFAULT_PATH_SPLIT_USR,
"container=systemd-nspawn", /* LXC sets container=lxc, so follow the scheme here */
NULL, /* TERM */
NULL, /* HOME */
diff --git a/src/shared/path-util.h b/src/shared/path-util.h
index 0a42de7..1e58e1b 100644
--- a/src/shared/path-util.h
+++ b/src/shared/path-util.h
@@ -25,10 +25,13 @@
#include "macro.h"
+#define DEFAULT_PATH_NORMAL "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin"
+#define DEFAULT_PATH_SPLIT_USR DEFAULT_PATH_NORMAL ":/sbin:/bin"
+
#ifdef HAVE_SPLIT_USR
-# define DEFAULT_PATH "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
+# define DEFAULT_PATH DEFAULT_PATH_SPLIT_USR
#else
-# define DEFAULT_PATH "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin"
+# define DEFAULT_PATH DEFAULT_PATH_NORMAL
#endif
bool is_path(const char *p) _pure_;
From: =?utf-8?q?Zbigniew_J=C4=99drzejewski-Szmek?= <zbyszek@in.waw.pl>
Date: Tue, 4 Mar 2014 09:50:26 -0500
Subject: Do not print invalid UTF-8 in error messages
Inexplicably, 550a40ec ('core: do not print invalid utf-8 in error
messages') only fixed two paths. Convert all of them now.
(cherry picked from commit b5d742138f71e87312541a89aac5657015f50f48)
Conflicts:
src/core/load-fragment.c
src/shared/conf-parser.c
---
src/core/load-fragment.c | 11 +++--------
src/shared/conf-parser.c | 6 ++----
src/shared/conf-parser.h | 6 ++++++
src/shared/fileio.c | 9 ++++++---
4 files changed, 17 insertions(+), 15 deletions(-)
diff --git a/src/core/load-fragment.c b/src/core/load-fragment.c
index f01843d..d6ac4f6 100644
--- a/src/core/load-fragment.c
+++ b/src/core/load-fragment.c
@@ -515,9 +515,7 @@ int config_parse_exec(const char *unit,
}
if (!utf8_is_valid(path)) {
- log_syntax(unit, LOG_ERR, filename, line, EINVAL,
- "Path is not UTF-8 clean, ignoring assignment: %s",
- rvalue);
+ log_invalid_utf8(unit, LOG_ERR, filename, line, EINVAL, rvalue);
r = 0;
goto fail;
}
@@ -532,9 +530,7 @@ int config_parse_exec(const char *unit,
}
if (!utf8_is_valid(c)) {
- log_syntax(unit, LOG_ERR, filename, line, EINVAL,
- "Path is not UTF-8 clean, ignoring assignment: %s",
- rvalue);
+ log_invalid_utf8(unit, LOG_ERR, filename, line, EINVAL, rvalue);
r = 0;
goto fail;
}
@@ -1803,8 +1799,7 @@ int config_parse_unit_requires_mounts_for(
return log_oom();
if (!utf8_is_valid(n)) {
- log_syntax(unit, LOG_ERR, filename, line, EINVAL,
- "Path is not UTF-8 clean, ignoring assignment: %s", rvalue);
+ log_invalid_utf8(unit, LOG_ERR, filename, line, EINVAL, rvalue);
continue;
}
diff --git a/src/shared/conf-parser.c b/src/shared/conf-parser.c
index 6085d33..4ac71ed 100644
--- a/src/shared/conf-parser.c
+++ b/src/shared/conf-parser.c
@@ -607,8 +607,7 @@ int config_parse_path(const char *unit,
assert(data);
if (!utf8_is_valid(rvalue)) {
- log_syntax(unit, LOG_ERR, filename, line, EINVAL,