Commit Graph

34029 Commits

Author SHA1 Message Date
Lennart Poettering 96b2fb93c5 tree-wide: beautify remaining copyright statements
Let's unify an beautify our remaining copyright statements, with a
unicode ©. This means our copyright statements are now always formatted
the same way. Yay.
2018-06-14 10:20:21 +02:00
Lennart Poettering 0c69794138 tree-wide: remove Lennart's copyright lines
These lines are generally out-of-date, incomplete and unnecessary. With
SPDX and git repository much more accurate and fine grained information
about licensing and authorship is available, hence let's drop the
per-file copyright notice. Of course, removing copyright lines of others
is problematic, hence this commit only removes my own lines and leaves
all others untouched. It might be nicer if sooner or later those could
go away too, making git the only and accurate source of authorship
information.
2018-06-14 10:20:20 +02:00
Lennart Poettering 2aafd60bee grypt-util: drop two emacs modelines
No idea why they didn't get removed earlier...
2018-06-14 10:20:20 +02:00
Lennart Poettering 2680a763b8 po: drop copyright lines referencing COPYRIGHT HOLDER
These lines are template lines that never got filled in. Let's drop
them, as they carry zero information and are just useless.
2018-06-14 10:20:20 +02:00
Lennart Poettering 810adae9e9 tree-wide: use proper unicode © instead of (C) where we can
Let's use a proper unicode copyright symbol where we can, it's prettier.

This important patch is very important.
2018-06-14 10:20:20 +02:00
Lennart Poettering 818bf54632 tree-wide: drop 'This file is part of systemd' blurb
This part of the copyright blurb stems from the GPL use recommendations:

https://www.gnu.org/licenses/gpl-howto.en.html

The concept appears to originate in times where version control was per
file, instead of per tree, and was a way to glue the files together.
Ultimately, we nowadays don't live in that world anymore, and this
information is entirely useless anyway, as people are very welcome to
copy these files into any projects they like, and they shouldn't have to
change bits that are part of our copyright header for that.

hence, let's just get rid of this old cruft, and shorten our codebase a
bit.
2018-06-14 10:20:20 +02:00
Franck Bui 16dc38dd15 locale-util: on overlayfs FTW_MOUNT causes nftw(3) to not list *any* files
On overlayfs, FTW_MOUNT causes nftw to not list *any* files because the
condition used by glibc to verify that it's on the same mountpoint doesn't work
on overlayfs, see https://bugzilla.suse.com/show_bug.cgi?id=1096807 for the
details.

However using FTW_MOUNT doesn't seem to be really needed when walking through
the keymap directorie tree. So until the glibc or the kernel is fixed (which
might take some time), let's make localectl works with overlayfs.

There's a small side effect here, by which regular (non-directory) files with
bind mounts will be parsed while they were skipped by the previous logic.
2018-06-14 10:19:33 +02:00
Yu Watanabe ead0adb161 timedatectl: add 'show' command to display machine-readable output
Closes #9249.
2018-06-14 10:19:08 +02:00
Lennart Poettering 28e1a3ec44
Merge pull request #9193 from keszybz/coverity
Coverity support for glibc-2.27
2018-06-14 09:59:58 +02:00
Iwan Timmer c9299be2f5 resolve: rename PrivateDNS to DNSOverTLS
PrivateDNS is not considered a good name for this option, so rename it to DNSOverTLS
2018-06-14 09:57:56 +02:00
Zbigniew Jędrzejewski-Szmek d122ed1ba8
Merge pull request #9263 from poettering/log-serialize
save/restore log level across daemon reexec
2018-06-14 09:57:15 +02:00
Lennart Poettering 08ebe56b2e
Merge pull request #9291 from poettering/nspawn-fixlets
tiny nspawn fixlets
2018-06-13 19:16:34 +02:00
Lennart Poettering f0d97606e9
Merge pull request #9290 from poettering/radv-fixlets
tiny sd-radv fixlets
2018-06-13 19:05:57 +02:00
Yu Watanabe 24f5a4c7c6 machine: ignore containers which disable private user namespace in MapToMachine{User,Group}
Fixes #9286.
2018-06-13 19:05:32 +02:00
Lennart Poettering b5752d2352 main: simplify arg_system initialization a bit
For both branches of the if check it's the first line, hence let's just
do it before.
2018-06-13 18:52:27 +02:00
Franck Bui bda7d78ba1 pid1: preserve current value of log target across re-{load,execution}
To make debugging easier, this patches allows one to change the log target and
do reload/reexec without modifying configuration permanently, which makes
debugging easier.

Indeed if one changed the log target at runtime (via the bus or via signals),
the change was lost on the next reload/reexecution.

In order to restore back the default value (set via system.conf, environment
variables or any other means ), the empty string in the "LogTarget" property is
now supported as well as sending SIGTRMIN+26 signal.
2018-06-13 18:52:27 +02:00
Franck Bui a6ecbf836c pid1: preserve current value of log level across re-{load,execution}
To make debugging easier, this patches allows one to change the log level and
do reload/reexec without modifying configuration permanently, which makes
debugging easier.

Indeed if one changed the log max level at runtime (via the bus or via
signals), the change was lost on the next daemon reload/reexecution.

In order to restore the original value back (set via system.conf, environment
variables or any other means), the empty string in the "LogLevel" property is
now supported as well as sending SIGRTMIN+23 signal.
2018-06-13 18:52:27 +02:00
Lennart Poettering df1fac6dea nspawn: free global variables before exiting
This doesn't really matter much, but is prettier for valgrind
2018-06-13 17:51:40 +02:00
Lennart Poettering 97d7974b18 sd-radv: use strv_isempty() where we can 2018-06-13 17:48:15 +02:00
Lennart Poettering f5a5706ace sd-radv: normalize function parameters a bit
Let's add "const" where we don't change structures passed.

Also, we generally use "unsigned char" for IP prefix length values, do
so here too. Previously different parts of the sd-radv.h API used
different types for this.
2018-06-13 17:48:15 +02:00
Lennart Poettering c4b6dda07f sd-radv: close fd when destroying object 2018-06-13 17:48:15 +02:00
Lennart Poettering 2f14e52f08 nspawn: drop unused parameter from one call 2018-06-13 17:42:16 +02:00
Susant Sahani 6f8a8b84f2 networkd: Don't try to close fd in sd_radv_stop if fd is closed.
sd_radv_stop is called from two places. if sd_radv_stop is alrady
success then just don't try to close it .
```
systemd-networkd[604]: RADV: Stopping IPv6 Router Advertisement daemon
systemd-networkd[604]: RADV: Unable to send last Router Advertisement with router lifetime set to zero: Bad file descriptor <==================HERE
systemd-networkd[604]: RADV: Updated prefix 2a0a:*:*:fc::/64 preferred 1h valid 2h
systemd-networkd[604]: RADV: Started IPv6 Router Advertisement daemon
```

Closes one of the issue #8960
2018-06-13 17:14:47 +02:00
Lennart Poettering cb8770ed21
Merge pull request #9261 from keszybz/drop-bool-casts
Drop bool casts
2018-06-13 16:19:24 +02:00
Lennart Poettering d5ef342dfe hwdb-update: make sure it works when run from meson
let's make the argument optional again, so that the command line "ninja
-C build hwdb-update" runs works.
2018-06-13 14:20:03 +02:00
Lennart Poettering 38dd5600b3 hwdb: update from upstream 2018-06-13 14:20:03 +02:00
Lennart Poettering 9539a9d3db terminal-util: make file names in --cat-config output clickable links 2018-06-13 14:20:03 +02:00
Lennart Poettering dcd5c891cb binfmt,sysctl,sysuers,tmpfiles: add auto-paging for --cat-config commands
The output of these commands is really long, and already enriched with
color. Let's add auto-paging to make this easier to digest.
2018-06-13 14:20:03 +02:00
Lennart Poettering ba1dc1a12b NEWS: add an example that actually applies 2018-06-13 14:20:03 +02:00
Lennart Poettering 75da262a13 NEWS: the tool is called resolvconf, without the inner e 2018-06-13 14:20:03 +02:00
Lennart Poettering fe903cf420 NEWS: break lines with emacs once more
Let's follow the line break rules our .dir-locals.el file defines
2018-06-13 14:20:03 +02:00
Lennart Poettering ec53d48c41 NEWS: some .mailmap work to clean up contributors list 2018-06-13 14:20:03 +02:00
Zbigniew Jędrzejewski-Szmek 23949111c0
Merge pull request #8863 from evelikov/shell-completion-fixes
Shell completion fixes/perf improvements
2018-06-13 14:09:14 +02:00
Zbigniew Jędrzejewski-Szmek 108ccae9e1 test-alloc-util: add casts to bools from p ointers
C++03: "An rvalue of arithmetic, enumeration, pointer, or pointer to member
type can be converted to an rvalue of type bool. A zero value, null pointer
value, or null member pointer value is converted to false; any other value is
converted to true"

C should behave the same because pointers are scalars in C, but let's verify
that.
2018-06-13 10:52:40 +02:00
Zbigniew Jędrzejewski-Szmek 5d904a6aaa tree-wide: drop !! casts to booleans
They are not needed, because anything that is non-zero is converted
to true.

C11:
> 6.3.1.2: When any scalar value is converted to _Bool, the result is 0 if the
> value compares equal to 0; otherwise, the result is 1.

https://stackoverflow.com/questions/31551888/casting-int-to-bool-in-c-c
2018-06-13 10:52:40 +02:00
Zbigniew Jędrzejewski-Szmek 37e744e866 test-alloc-util: add a "test" for bool casts
Just in case ;)

There is no good place, test-alloc-util.c is as good as any, and it's quite
short so far, so let's add this there.
2018-06-13 10:52:40 +02:00
Zbigniew Jędrzejewski-Szmek 3b253ad689 cocinelle: use GNU parallel to run spatch
spatch is single-threaded, i.e. slow. On my machine it allocates 5 GB of memory
and starts swapping, which makes it even slower. Using parallel makes the whole
thing pleasantly fast.
2018-06-13 10:52:33 +02:00
Zbigniew Jędrzejewski-Szmek fbbe6d65b4 basic/parse-util: remove unnecessary parentheses 2018-06-13 10:43:38 +02:00
Zbigniew Jędrzejewski-Szmek b961fbd4ee
Merge pull request #9172 from yuwata/timesync-ntp-parser
timesync: check validity of NTP server name or address
2018-06-13 08:52:58 +02:00
Zbigniew Jędrzejewski-Szmek 6f534ceb95
Merge pull request #9280 from yuwata/follow-ups-8849
Several follow-ups for #8849
2018-06-13 08:46:07 +02:00
Yu Watanabe 73c718a9e5 NEWS: add more news 2018-06-13 08:27:14 +02:00
Zbigniew Jędrzejewski-Szmek 70127be805
Merge pull request #9153 from poettering/private-mounts
introduce PrivateMounts= setting and clean up documentation for MountFlags=
2018-06-13 08:20:18 +02:00
Lennart Poettering c086ce8c2e NEWS: announce DNS-over-TLS too 2018-06-13 14:39:53 +09:00
Yu Watanabe 87cbe069e6 man: drop unnecessary '=' after nta 2018-06-13 14:34:26 +09:00
Yu Watanabe 92936883d5 resolvectl: fix indentation 2018-06-13 14:30:51 +09:00
Yu Watanabe ba0c011eee timesync: add more log messages in manager_network_read_link_servers() 2018-06-13 14:05:26 +09:00
Yu Watanabe dcb37458cb timesync: check validity of NTP server name or address 2018-06-13 13:51:17 +09:00
Yu Watanabe 8e7b5bd047 conf-parser: simplify conf_parse_path()
Follow-up for 97651797e83d0548aef9f808657d3518d89e5aee.
2018-06-13 13:50:35 +09:00
Yu Watanabe daab72ea44 resolve: do not complete stream transaction when it is under retrying 2018-06-13 13:43:36 +09:00
Yu Watanabe 3da3cdd592 resolve: drop unused argument of dns_server_packet_lost() 2018-06-13 13:20:23 +09:00