summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAge
* conf-parser: accept trailing backslash at the end of the file (#8941)Filipe Brandenburger2018-06-28
| | | | | | | | | | | | This makes it behave the same whether there is a blank line or not at the end of the file. This is also consistent with the behavior of the shell on a shell script that ends on a trailing backslash at the last line. Added tests to test_config_parse(), which only pass if the corresponding change to config_parse() is included. (cherry picked from commit 4f29e0db127dce9e1a28af4d7bf88c124ba257b7)
* login: do not wall message on cancelling shutdown when ↵Yu Watanabe2018-06-28
| | | | | | | | Manager.enable_wall_messages is false Fixes #8904. (cherry picked from commit 6e78fa4afd474dae984f3ee4a8477c623296a519)
* virt: if we detect Xen by DMI, trust that over CPUIDLennart Poettering2018-06-28
| | | | | | | | Apparently Xen sometimes lies about its identity when queried via CPUID. Let's hence prefer DMI tests for CPUID Fixes: #8844 (cherry picked from commit f2fe2865cd19cd4318b82d01b9b62d22b1697b3a)
* meson: drop 'name' argument in cc.has_argument() (#8878)Yu Watanabe2018-06-28
| | | | (cherry picked from commit b0903bb585d2158f78a4cf603fde4aed5474e2b9)
* add __nr_statx defines for extra architectures (#8872)Adam Duskett2018-06-28
| | | | | | | | | | | | | This includes: - arm - arm64 - alpha - powerpc64 - sparc Taken from kernel 4.16.6 (cherry picked from commit 773c84349d80c7a6f818f5909a160ddb7337987f)
* basic/log: always ignore errno from the enviornment (#8841)Zbigniew Jędrzejewski-Szmek2018-06-28
| | | | | | | | | | | | | This extends the change done in b29f6480ec to other logging functions. This actually fixes some bugs in callers of log_struct(), for example config_parse_alias() called 'return log_syntax(..., 0, ...)' which could result in a bogus non-zero return value. Calls to log_object() and log_format_iovec() — which is only used by server_driver_message() — appear correct. (cherry picked from commit d1a1f0aaf0d2f08c60d1e0d32e646439d99f58dc)
* cgroup-util: fix enabling of controllers (#8816)Antique2018-06-28
| | | | | | | | | | | | If enabling controller for some reason fails we need to clear error for the FILE stream. Enabling remaining controllers would otherwise fail because write_string_stream_ts() checks for ferror(f) and returns -EIO if there is one. Broken by commit <77fa610b22>. Signed-off-by: Pavel Hrdina <phrdina@redhat.com> (cherry picked from commit 96aa6591d1103b8cca9a4db80ba478a18bdf3e9a)
* meson: drop 'name' argument in cc.has_argument() (#8823)Yu Watanabe2018-06-28
| | | | | | | | | | | | | | | | | | This fixes the following warning with clang and meson-0.46.0, ``` WARNING: Passed invalid keyword argument "name". WARNING: This will become a hard error in the future. WARNING: Passed invalid keyword argument "name". WARNING: This will become a hard error in the future. Compiler for C supports arguments -Wno-typedef-redefinition: YES WARNING: Passed invalid keyword argument "name". WARNING: This will become a hard error in the future. WARNING: Passed invalid keyword argument "name". WARNING: This will become a hard error in the future. Compiler for C supports arguments -Wno-gnu-variable-sized-type-not-at-end: YES ``` (cherry picked from commit 8ac42236b09d2f21f962bf72fcbeee24502f959f)
* man: fix description of --value option for loginctl (#8820)Yu Watanabe2018-06-28
| | | | (cherry picked from commit ad628501b95b83ac6c0b42bb69db7e1b38c0ff13)
* fileio.c: fix incorrect mtimeChris Lesiak2018-06-28
| | | | | | | | | | | | | | | | | A regression was introduced that caused the mtime of /etc/.updated and /var/.updated to be the current time when systemd-update-done ran instead of being copied from /usr. This was nearly fixed, but due to fflush being called after mtime was carefully set, it was overwritten with the current time. Regression introduced in 872c40396384f9fa89b01baf4e739d28ed590299 A fix was just missed in 39c38d773fbe2b4f76ff29ecd3344640efb9a86c Fixes #8806 (cherry picked from commit be83711c7eb6a09e0d0c529c427cebcae87c0c1f)
* basic/log: do not use global errno in log_*_errno()Zbigniew Jędrzejewski-Szmek2018-06-28
| | | | | | | | | | | | | | | | | | | | | | | | Quoting https://github.com/systemd/systemd/pull/8760#discussion_r183321060: > When we originally added the errno patching we went for a "best of both > worlds" approach, i.e. that we override errno if an error is specified, but > if no error is specified (i.e. 0 is passed as error code) then we use the > previously set errno, similar in style how plain `printf()` would do it. In > retrospect I think we almost never purposefully made use of the second, > i.e. the plain `printf()` logic, but we multiple times ran into this case > accidentally and introduced a bug. Hence yes, it probably makes sense to > switch this over, and consistently ignore the `errno` already set and always > override it with the error passed in. The only problem I see with that is: I > wonder if there might be a case or two lurking somewhere where we actually > made use of the "best of both worlds" approach, and if so, if we can detect > where... (But then again, even if there is, and we fail to find those cases, > maybe that's not all bad, as it's just a few new bugs against probably fixing > many more old and future bugs, if you follow what I mean). I scanned our codebase, and found some bugs in the value passed to log_*_errno, but no intentional cases of error=0 being passed. (cherry picked from commit b29f6480eca0550ba65d30fbece8dd4d4bfe666d)
* basic/audit-util: always log the reason when disabling audit logsZbigniew Jędrzejewski-Szmek2018-06-28
| | | | | | This state is cached, and it's seems OK to log at least once. (cherry picked from commit 13bb68bbe37f0b39cd45234b09fb1a1da8302020)
* ISO-C compatibility: Remove empty initializer (#8713)Leonard2018-06-28
| | | | | | | | | | ISO-C doesn't allow empty initializers, so replace it by explicitly initializing to zero. Also add braces because x is a union and we initialize a subobject, so a compiler might warn about suggesting braces. Shut that up. (cherry picked from commit d579a56c397a1aeaa490032a9f7aabd82124f1c8)
* tmpfiles: add a new return code for "operational failure" when processingZbigniew Jędrzejewski-Szmek2018-06-28
| | | | | | | | | | Things can fail, and we have no control over it: - file system issues (immutable bits, file system errors, MAC refusals, etc) - kernel refusing certain arguments when writing to /proc/sys or /sys Let's add a new code for the case where we parsed configuration but failed to execute it because of external errors. (cherry picked from commit bb9947be2fa308d198b63b30e494ade5d68e5109)
* core: skip the removal of cgroups in the TEST_RUN_MINIMAL mode (#8622)Evgeny Vereshchagin2018-06-28
| | | | | | | | | When `systemd` is run in the TEST_RUN_MINIMAL mode, it doesn't really set up cgroups, so it shouldn't try to remove anything. Closes https://github.com/systemd/systemd/issues/8474. (cherry picked from commit f6c63f6fc90040f0017a7cc37f3a05d5b86226d7)
* systemd-inhibit: ignore signal interrupt from keyboard (#8569)Christian Hesse2018-06-28
| | | | | | | | | | | | | By default both processes, systemd-inhibit and the forked one, receive the signals. Pressing Ctrl+C on the keyboard results in SIGINT being sent to the processes, followed by SIGTERM being sent to the forked process when systemd-inhibit exits. This can cause trouble when the forked process does not clean up properly but exit immediately. Instead make systemd-inhibit ignore SIGINT, leaving it to the forked process to clean up and exit. (cherry picked from commit 106f12a08fcacef713438fc055872592399deeed)
* stat-util: fix fd_is_network_ns()Lennart Poettering2018-06-28
| | | | | | | This was broken in 77f9fa3b8ea46c27e5a5e9270f71bf1b4000c3e0. My fault. Fixes: #8543 (cherry picked from commit 29f74559d4dc6ea41232233d32f1a92bcee43626)
* sd-bus: drop fd_nonblock() calls that are implied by rearrange_stdio() (#8514)Lennart Poettering2018-06-28
| | | | (cherry picked from commit 68b525d1d1e8153cbc2e2354fa650aa165f7a434)
* meson: add note about coreutils version with ln --relativeZbigniew Jędrzejewski-Szmek2018-06-28
| | | | | https://bugs.freedesktop.org/show_bug.cgi?id=90799 (cherry picked from commit cd001016a166bb849c454e7b5cdb58053f34935b)
* basic/macros: rename noreturn into _noreturn_ (#8456)Franck Bui2018-06-28
| | | | | | | | | | | | | | | "noreturn" is reserved and can be used in other header files we include: [ 16s] In file included from /usr/include/gcrypt.h:30:0, [ 16s] from ../src/journal/journal-file.h:26, [ 16s] from ../src/journal/journal-vacuum.c:31: [ 16s] /usr/include/gpg-error.h:1544:46: error: expected ‘,’ or ‘;’ before ‘)’ token [ 16s] void gpgrt_log_bug (const char *fmt, ...) GPGRT_ATTR_NR_PRINTF(1,2); Here we include grcrypt.h (which in turns include gpg-error.h) *after* we "noreturn" was defined in macro.h. (cherry picked from commit 848e863acc51ecfb0f3955c498874588201d9130)
* tests: make / private after creating a mount namespaceEvegeny Vereshchagin2018-06-28
| | | | | | so that the test never affects the root namespace. (cherry picked from commit c58fd466a313a1f93df1792822e358c67990bcdf)
* core: ignore errors from cg_create_and_attach() in test mode (#8401)Michal Sekletar2018-06-28
| | | | | | | | | | | | | | | | | | | | | | | | Reproducer: $ meson build && cd build $ ninja $ sudo useradd test $ sudo su test $ ./systemd --system --test ... Failed to create /user.slice/user-1000.slice/session-6.scope/init.scope control group: Permission denied Failed to allocate manager object: Permission denied Above error message is caused by the fact that user test didn't have its own session and we tried to set up init.scope already running as user test in the directory owned by different user. Let's try to setup cgroup hierarchy, but if that fails return error only when not running in the test mode. Fixes #8072 (cherry picked from commit aa77e234fce7413b7dd64f99ea51450f2e2e9dbd)
* meson: avoid warning about comparison of bool and stringZbigniew Jędrzejewski-Szmek2018-06-28
| | | | | | | meson.build:2907: WARNING: Trying to compare values of different types (bool, str) using ==. The result of this is undefined and will become a hard error in a future Meson release. (cherry picked from commit af4d7860c4e757f34a02ca73a0b14c73c18f8b30)
* basic/cgroup-util: remove unused variableZbigniew Jędrzejewski-Szmek2018-06-28
| | | | (cherry picked from commit eef03d70c1bedb3aabd4e2bcf10ab1f2678443bf)
* core: do not free heap-allocated strings (#8391)Yu Watanabe2018-06-28
| | | | | | Fixes #8387. (cherry picked from commit 5cbaad2f6795088db56063d20695c6444595822f)
* sd-bus: do not try to close already closed fd (#8392)Yu Watanabe2018-06-28
| | | | | | Fixes #8376, which is introduced by 2b33ab0957f453a06b58e4bee482f2c2d4e100c1. (cherry picked from commit 280029d18f470a64403d68717eef1be5274ff8af)
* NEWS: fix typos in v238 section (#8369)Tomasz Torcz2018-06-28
| | | | (cherry picked from commit 07a35e846b7986d3c02eca99fa291f6869035c58)
* Add locale.h header, needed by freelocale()Danilo Spinella2018-06-22
| | | | | Without locale.h, there is an implicit declaration of function `freelocale`, which is reported as error by -Werror=implicit-function-declaration.
* Prep v238: Make a real distinction between 'halt' and 'poweroff'.Sven Eden2018-06-12
|
* Prep v238: Fix cg_path_decode_unit() to understand elogind session naming.Sven Eden2018-06-11
| | | | (cherry picked from commit d8949c3072a4b984d6fa964178a2d8d945ecbcb6)
* Prep v238: Fix elogind_daemonize(), it failed due to some misunderstandings ↵Sven Eden2018-06-08
| | | | | | on my side. (cherry picked from commit 1c9629692145891f10a36227749470d87979dd0b)
* logind-user.c: As we need special.h elsewhere now, use it here, too.Sven Eden2018-06-08
| | | | (cherry picked from commit a96cb75c17b008312fca8f81bc2a126f8a87850c)
* pam_elogind.c: Remove renames by mask, check_tree.pl can handle this now.Sven Eden2018-06-08
| | | | (cherry picked from commit 6964ec46218d41d699690ed590026249969b2257)
* meson.build: remove unnecessary `ln --relative` checkKylie McClain2018-06-08
| | | | | | | `ln --relative` is used by tools/meson-make-symlink.sh, which is never once ran during the build process for elogind. additionally, it incurrs a dependency on GNU coreutils (or any other `ln` that has the non-standard `--relative` extension), so there's no real need to check for it.
* Add https://github.com/Yamakuzure/pwx-elogind-migration-tools.git as ↵Sven Eden2018-06-06
| | | | submodule 'pwx'
* Rename pwx to pwx_local as a backup.Sven Eden2018-06-06
|
* pwx/last_mutual_commits.csv: Add last mutual before branching out v238-stableSven Eden2018-06-05
|
* Prep v238: Uncomment now needed headers and unmask now needed functions in ↵Sven Eden2018-06-05
| | | | src/test (6/6)
* Prep v238: Uncomment now needed headers and unmask now needed functions in ↵Sven Eden2018-06-05
| | | | src/shared (5/6)
* Prep v238: Uncomment now needed headers and unmask now needed functions in ↵Sven Eden2018-06-05
| | | | src/login (4/6)
* Prep v238: Uncomment now needed headers and unmask now needed functions in ↵Sven Eden2018-06-05
| | | | src/libelogind (3/6)
* Prep v238: Uncomment now needed headers and unmask now needed functions in ↵Sven Eden2018-06-05
| | | | src/core (2/6)
* Prep v238: Uncomment now needed headers and unmask now needed functions in ↵Sven Eden2018-06-05
| | | | src/basic (1/6)
* Prep v238: Apply some upstream fixes to the sections elogind pendants.Sven Eden2018-06-05
|
* Prep v238: Remove obsolete sources and add missing new ones.Sven Eden2018-06-05
|
* Prep v238: removed superfluous files that slithered in during upstream ↵Sven Eden2018-06-04
| | | | commit migration.
* Prep v238: Fixed meson.build files in src/shared and src/testSven Eden2018-06-04
|
* Prep v238: Applied some upstream updates to src/libelogind (5/5)Sven Eden2018-06-04
|
* Prep v238: Applied some upstream updates to src/core (4/5)Sven Eden2018-06-04
|
* Prep v238: Applied some upstream updates to src/basic (3/5)Sven Eden2018-06-04
|