diff options
author | Benjamin Berg <bberg@redhat.com> | 2022-01-10 12:35:46 +0100 |
---|---|---|
committer | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2022-01-12 22:26:22 +0100 |
commit | 5d3466ec91b05853b815db509b901e6a6d5f4db4 (patch) | |
tree | 168e298fa7b41f8c3231ac1c54c96841f51e06f6 | |
parent | c2cb950d4b78db4aec32ccc3c39897184b82a9bd (diff) | |
download | systemd-5d3466ec91b05853b815db509b901e6a6d5f4db4.tar.gz |
xdg-autostart-service: Ignore missing desktop-sepcific condition binary
If a desktop specific ExecCondition= binary does not exist, this just
means that the desktop environment is not available. As such, it is not
an error condition that should prevent the service from being installed
in the .wants target.
Fix this by simply returning zero.
(cherry picked from commit 6d0aef1dd15088e7379681b3bd93c3cb450f3c55)
(cherry picked from commit 19fbd7764da2e23a89e27b4d95afd77b99f4be87)
-rw-r--r-- | src/xdg-autostart-generator/xdg-autostart-service.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/xdg-autostart-generator/xdg-autostart-service.c b/src/xdg-autostart-generator/xdg-autostart-service.c index fe73bfe9db..16545beb50 100644 --- a/src/xdg-autostart-generator/xdg-autostart-service.c +++ b/src/xdg-autostart-generator/xdg-autostart-service.c @@ -486,7 +486,7 @@ static int xdg_autostart_generate_desktop_condition( log_full_errno(r == -ENOENT ? LOG_DEBUG : LOG_WARNING, r, "%s not found: %m", test_binary); fprintf(f, "# ExecCondition using %s skipped due to missing binary.\n", test_binary); - return r; + return 0; } e_autostart_condition = cescape(condition); |