]> git.ipfire.org Git - thirdparty/systemd.git/log
thirdparty/systemd.git
5 years agogitignore: add .gdb_history 9600/head
Zbigniew Jędrzejewski-Szmek [Mon, 16 Jul 2018 14:03:47 +0000 (16:03 +0200)] 
gitignore: add .gdb_history

This is the default file gdb will use.

5 years agoMerge pull request #9550 from nosada/fix-9549
Yu Watanabe [Mon, 16 Jul 2018 14:02:32 +0000 (23:02 +0900)] 
Merge pull request #9550 from nosada/fix-9549

format-table: make all widths be set properly

5 years agosystemctl: allow 'edit' to work on templates again
Zbigniew Jędrzejewski-Szmek [Mon, 16 Jul 2018 13:18:21 +0000 (15:18 +0200)] 
systemctl: allow 'edit' to work on templates again

This got broken in 9d9dd746d461e4524fb3644b20b8138448d666f2, because a template
is not a valid unit, so the check for being masked failed. Avoid this by
handling templates specially. Fixes #9554.

Also, this improves 'cat' with masked units:

(before) $ systemctl cat foofoofoo@.service
Failed to derive unit name prefix from unit name: Invalid argument
Failed to derive unit name prefix from unit name: Invalid argument
Failed to derive unit name prefix from unit name: Invalid argument
Failed to derive unit name prefix from unit name: Invalid argument
Failed to derive unit name prefix from unit name: Invalid argument
Failed to derive unit name prefix from unit name: Invalid argument
Failed to derive unit name prefix from unit name: Invalid argument
Failed to derive unit name prefix from unit name: Invalid argument
Failed to derive unit name prefix from unit name: Invalid argument
Failed to derive unit name prefix from unit name: Invalid argument

(after) $ build/systemctl cat foofoofoo@.service

In check_triggering_units(), the call to unit_is_masked() is replaced with an
open-coded check. This is a bit unfortunate, but unit_is_masked() now requires
LookupPaths to be initialized, which we don't have or need in this case, so it
seems easiest to just accept this tiny code duplication.

5 years agosd-bus: make BUS_DEFAULT_TIMEOUT configurable
Yu Watanabe [Fri, 13 Jul 2018 08:38:47 +0000 (17:38 +0900)] 
sd-bus: make BUS_DEFAULT_TIMEOUT configurable

This adds sd_bus_{get,set}_method_call_timeout().
If the timeout is not set or set to 0, then the timeout value is
parsed from $SYSTEMD_BUS_TIMEOUT= environment variable. If the
environment variable is not set, then built-in timeout is used.

5 years agoMerge pull request #9530 from keszybz/sd-bus-doc
Lennart Poettering [Mon, 16 Jul 2018 13:01:12 +0000 (15:01 +0200)] 
Merge pull request #9530 from keszybz/sd-bus-doc

More documentation for sd-bus

5 years agoMove module-util.h to src/shared/ and load_module() to libshared
Zbigniew Jędrzejewski-Szmek [Fri, 6 Jul 2018 09:57:54 +0000 (11:57 +0200)] 
Move module-util.h to src/shared/ and load_module() to libshared

Unfortunately this needs libshared to link to libkmod. Before it was linked
into systemd-udevd, udevadm, and systemd each seperately. On most systems this
doesn't make much difference, because at least systemd would be installed, but
it might not be in small chroots. It is a small library, so I hope this is not
a big issue.

5 years agotree-wide: use "polkit" to refer to PolicyKit/polkit 9530/head
Zbigniew Jędrzejewski-Szmek [Mon, 16 Jul 2018 10:44:24 +0000 (12:44 +0200)] 
tree-wide: use "polkit" to refer to PolicyKit/polkit

Back in 2012 the project was renamed, see the release notes for v 0.105
[https://cgit.freedesktop.org/polkit/tree/NEWS#n754]. Let's update our
documentation and comments to do the same. Referring to PolicyKit is confusing
to users because at the time the polkit api changed too, and we support the new
version. I updated NEWS too, since all the references to PolicyKit there were
added after the rename.

"PolicyKit" is unchanged in various URLs and method call names.

5 years agomeson: allow systemd.directives and .index to be built if -Dman=false
Zbigniew Jędrzejewski-Szmek [Sun, 8 Jul 2018 13:14:46 +0000 (15:14 +0200)] 
meson: allow systemd.directives and .index to be built if -Dman=false

See 559d215b6733bb46533a52080522a7feca183aa8 for justification.

5 years agoman: add sd_bus_set_description(3)
Zbigniew Jędrzejewski-Szmek [Sun, 8 Jul 2018 13:09:23 +0000 (15:09 +0200)] 
man: add sd_bus_set_description(3)

5 years agoman: add sd_bus_reply_method_error(3)
Zbigniew Jędrzejewski-Szmek [Sun, 8 Jul 2018 12:11:13 +0000 (14:11 +0200)] 
man: add sd_bus_reply_method_error(3)

5 years agoman: add sd_bus_message_copy(3)
Zbigniew Jędrzejewski-Szmek [Sun, 8 Jul 2018 11:51:18 +0000 (13:51 +0200)] 
man: add sd_bus_message_copy(3)

5 years agoman: add sd_bus_message_new_error(3)
Zbigniew Jędrzejewski-Szmek [Sun, 8 Jul 2018 10:49:32 +0000 (12:49 +0200)] 
man: add sd_bus_message_new_error(3)

5 years agotest: Drop SKIP_INITRD for QEMU-based tests 9597/head
Michael Biebl [Mon, 16 Jul 2018 09:27:44 +0000 (11:27 +0200)] 
test: Drop SKIP_INITRD for QEMU-based tests

Not all distros support booting without an initrd. E.g. the Debian
kernel builds ext4 as a module and so relies on an initrd to
successfully start the QEMU-based images.

5 years agobuild-sys: Detect whether struct statx is defined in sys/stat.h
Filipe Brandenburger [Mon, 16 Jul 2018 05:43:35 +0000 (22:43 -0700)] 
build-sys: Detect whether struct statx is defined in sys/stat.h

Starting with glibc 2.27.9000-36.fc29, include file sys/stat.h will have a
definition for struct statx, in which case include file linux/stat.h should be
avoided, in order to prevent a duplicate definition.

    In file included from ../src/basic/missing.h:18,
     from ../src/basic/util.h:28,
     from ../src/basic/hashmap.h:10,
     from ../src/shared/bus-util.h:12,
     from ../src/libsystemd/sd-bus/bus-creds.c:11:
    /usr/include/linux/stat.h:99:8: error: redefinition of ‘struct statx’
     struct statx {
    ^~~~~
    In file included from /usr/include/sys/stat.h:446,
     from ../src/basic/util.h:19,
     from ../src/basic/hashmap.h:10,
     from ../src/shared/bus-util.h:12,
     from ../src/libsystemd/sd-bus/bus-creds.c:11:
    /usr/include/bits/statx.h:36:8: note: originally defined here
     struct statx
    ^~~~~

Extend our meson.build to look for struct statx when only sys/stat.h is
included and, in that case, do not include linux/stat.h anymore.

Tested that systemd builds correctly when using a glibc version that includes a
definition for struct statx.

glibc Fedora RPM update:
https://src.fedoraproject.org/rpms/glibc/c/28cb5d31fc1e5887912283c889689c47076278ae

glibc upstream commit:
https://sourceware.org/git/?p=glibc.git;a=commitdiff;h=fd70af45528d59a00eb3190ef6706cb299488fcd

5 years agologin: use parse_uid() when unmounting user runtime directory
Yu Watanabe [Mon, 9 Jul 2018 05:05:20 +0000 (14:05 +0900)] 
login: use parse_uid() when unmounting user runtime directory

When unmounting user runtime directory, only UID is necessary,
and the corresponding user may not exist anymore.
This makes first try to parse the input by parse_uid(), and only if it
fails, prase the input by get_user_creds().

Fixes #9541.

5 years agotest: Fix typo in TEST-19-DELEGATE
Michael Biebl [Sun, 15 Jul 2018 19:13:56 +0000 (21:13 +0200)] 
test: Fix typo in TEST-19-DELEGATE

5 years agoformat-table: fix typo in comment 9550/head
Yu Watanabe [Thu, 12 Jul 2018 08:23:07 +0000 (17:23 +0900)] 
format-table: fix typo in comment

5 years agotest: add a reproducer of issue #9549
Yu Watanabe [Thu, 12 Jul 2018 05:20:09 +0000 (14:20 +0900)] 
test: add a reproducer of issue #9549

5 years agoDo not apply uaccess tag for /dev/kvm if mode is 0666 9560/head
Michael Biebl [Fri, 13 Jul 2018 21:36:13 +0000 (23:36 +0200)] 
Do not apply uaccess tag for /dev/kvm if mode is 0666

5 years agoMerge pull request #9462 from yuwata/strv_split
Lennart Poettering [Fri, 13 Jul 2018 18:32:37 +0000 (20:32 +0200)] 
Merge pull request #9462 from yuwata/strv_split

make strv_split() accept empty string and use it in pager_open()

5 years agosd-bus: unref slot->match_callback.install_slot when slot is disconnected
Yu Watanabe [Sun, 8 Jul 2018 14:09:18 +0000 (23:09 +0900)] 
sd-bus: unref slot->match_callback.install_slot when slot is disconnected

When a slot is disconnected, then slot->match_callback.install_slot
is also disconnected. So, bus_slot_disconnect() removes the install_slot
from the list of slots in bus, although it is a floating object.
This makes install_slot unreffed from bus when it is disconnected.

Fixes #9505 and #9510.

5 years agoMerge pull request #9534 from martinpitt/nm-test
Lennart Poettering [Fri, 13 Jul 2018 17:50:14 +0000 (19:50 +0200)] 
Merge pull request #9534 from martinpitt/nm-test

Fix networkd test

5 years agomachinectl: fix verbosity of import-raw or friends
Yu Watanabe [Sun, 8 Jul 2018 16:14:37 +0000 (01:14 +0900)] 
machinectl: fix verbosity of import-raw or friends

This partially reverts 31d99bd172b17179ec24f63fc8ca4d6530dc98ae.

Fixes #9527.

5 years agopull: initialize libgcrypt before calling any functions provided by libgcrypt
Yu Watanabe [Sun, 8 Jul 2018 20:40:01 +0000 (05:40 +0900)] 
pull: initialize libgcrypt before calling any functions provided by libgcrypt

This fixes the following warning:
```
systemd-pull[4065]: Libgcrypt warning: missing initialization - please fix the application
```

5 years agobls: Allow options to be used more than once
Jan Janssen [Tue, 10 Jul 2018 08:44:06 +0000 (10:44 +0200)] 
bls: Allow options to be used more than once

This just documents what we already allow anyways.

5 years agoMerge pull request #9572 from yuwata/fix-9511
Lennart Poettering [Fri, 13 Jul 2018 17:32:09 +0000 (19:32 +0200)] 
Merge pull request #9572 from yuwata/fix-9511

resolve: fix heap-use-after-free and uninitialized memory

5 years agodoc: list PrivateMounts= in TRANSIENT-SETTINGS.md
Yu Watanabe [Thu, 12 Jul 2018 06:40:17 +0000 (15:40 +0900)] 
doc: list PrivateMounts= in TRANSIENT-SETTINGS.md

Follow-up for #9153.

5 years ago[man] minor systemd.target manual update
Michal Soltys [Fri, 13 Jul 2018 12:55:17 +0000 (14:55 +0200)] 
[man] minor systemd.target manual update

Target units gain both Conflicts= and Before= against shutdown.target
(not only Conflicts=).

5 years agohwdb: deprecate the POINTINGSTICK_CONST_ACCEL property
Peter Hutterer [Thu, 12 Jul 2018 22:39:09 +0000 (08:39 +1000)] 
hwdb: deprecate the POINTINGSTICK_CONST_ACCEL property

The only known consumer of this property was libinput but it stopped using
this property since libinput 1.9 (released Oct 2017). This property is
arguably not one that should be in systemd anyway - it's not a
hardware-specific property but rather a factor of the acceleration method
employed by whatever userspace handles the events.

Deprecate it but leave the values in place for backwards compatibility.

5 years agocore: add MemoryMin
Tejun Heo [Sat, 9 Jun 2018 00:33:14 +0000 (17:33 -0700)] 
core: add MemoryMin

The kernel added support for a new cgroup memory controller knob memory.min in
bf8d5d52ffe8 ("memcg: introduce memory.min") which was merged during v4.18
merge window.

Add MemoryMin to support memory.min.

5 years agohwdb: remove stray 'i' in hwdb match string for the HP Spectre (#9571)
Peter Hutterer [Thu, 12 Jul 2018 05:52:18 +0000 (15:52 +1000)] 
hwdb: remove stray 'i' in hwdb match string for the HP Spectre (#9571)

Looks like vim detritus, introduced in f8de7c1875841f277d0b0e46d4a27d4e2b893d1f

5 years agoformat-table: make all widths be set properly
NOGISAKA Sadata [Mon, 9 Jul 2018 14:49:07 +0000 (23:49 +0900)] 
format-table: make all widths be set properly

Fixes #9549.

5 years agoresolve: use structured initializer 9572/head
Yu Watanabe [Thu, 12 Jul 2018 04:37:01 +0000 (13:37 +0900)] 
resolve: use structured initializer

This fixes the following valgrind warning:
```
Syscall param sendmsg(msg.msg_name) points to uninitialised byte(s)
   at 0x6189CC1: sendmsg (in /usr/lib64/libpthread-2.27.so)
   by 0x153082: dns_stream_writev (resolved-dns-stream.c:235)
   by 0x153343: dns_stream_tls_writev (resolved-dns-stream.c:299)
   by 0x5B30343: ??? (in /usr/lib64/libgnutls.so.30.20.2)
   by 0x5B3158F: ??? (in /usr/lib64/libgnutls.so.30.20.2)
   by 0x5B33190: ??? (in /usr/lib64/libgnutls.so.30.20.2)
   by 0x5B36307: ??? (in /usr/lib64/libgnutls.so.30.20.2)
   by 0x5B37D47: gnutls_handshake (in /usr/lib64/libgnutls.so.30.20.2)
   by 0x154591: dns_stream_connect_tls (resolved-dns-stream.c:596)
   by 0x13A889: dns_transaction_emit_tcp (resolved-dns-transaction.c:676)
   by 0x13D901: dns_transaction_go (resolved-dns-transaction.c:1761)
   by 0x1330C8: dns_query_candidate_go (resolved-dns-query.c:156)
 Address 0xa9ac268 is 312 bytes inside a block of size 592 alloc'd
   at 0x4C30B06: calloc (vg_replace_malloc.c:711)
   by 0x1541F8: dns_stream_new (resolved-dns-stream.c:545)
   by 0x13A662: dns_transaction_emit_tcp (resolved-dns-transaction.c:642)
   by 0x13D901: dns_transaction_go (resolved-dns-transaction.c:1761)
   by 0x1330C8: dns_query_candidate_go (resolved-dns-query.c:156)
   by 0x134E16: dns_query_go (resolved-dns-query.c:757)
   by 0x11F3FB: bus_method_resolve_hostname (resolved-bus.c:353)
   by 0x4F947A7: method_callbacks_run (bus-objects.c:402)
   by 0x4F97266: object_find_and_run (bus-objects.c:1260)
   by 0x4F978B1: bus_process_object (bus-objects.c:1376)
   by 0x4FAF82C: process_message (sd-bus.c:2661)
   by 0x4FAFA1B: process_running (sd-bus.c:2703)
```

5 years agoresolve: unref stream after completion processes
Yu Watanabe [Thu, 12 Jul 2018 03:57:52 +0000 (12:57 +0900)] 
resolve: unref stream after completion processes

Fixes #9511.

5 years agocore: Fix grammar in error message
Sven Joachim [Sun, 8 Jul 2018 15:25:07 +0000 (17:25 +0200)] 
core: Fix grammar in error message

5 years agomeson: drop redundant messages
Yu Watanabe [Tue, 10 Jul 2018 14:58:39 +0000 (23:58 +0900)] 
meson: drop redundant messages

5 years agoRe-add uaccess tag for /dev/kvm
Michael Biebl [Tue, 10 Jul 2018 12:47:58 +0000 (14:47 +0200)] 
Re-add uaccess tag for /dev/kvm

If --dev-kvm-mode is set to something different then 0666, which we
explicitly support, it makes sense to still apply the uaccess tag to
/dev/kvm. For distros which opt to use the default 0666, this change is
a nop.

This partially reverts commit b8fd3d82205f632ce001fade74fed287e1564a1a.

5 years agorules: Add by-id symlinks for persistent memory
Keith Busch [Mon, 9 Jul 2018 21:23:25 +0000 (15:23 -0600)] 
rules: Add by-id symlinks for persistent memory

This patch adds a by-id symlink to persistent memory namespace if it
exports a uuid attribute. The result looks like the following example:

 # ls -l /dev/disk/by-id/*
 lrwxrwxrwx 1 root root 13 Jul  9 15:24 pmem-206dcdfe-69b7-4e86-a01b-f540621ce62e -> ../../pmem1.2
 lrwxrwxrwx 1 root root 13 Jul  9 15:24 pmem-73840bf1-4e74-4ba4-a9c8-8248934c07c8 -> ../../pmem1.1
 lrwxrwxrwx 1 root root 13 Jul  9 15:24 pmem-8137bdfd-3c4d-4b26-b326-21da3d4cd4e5 -> ../../pmem1.4
 lrwxrwxrwx 1 root root 13 Jul  9 15:24 pmem-f43d1b6e-3300-46cb-8afc-06d66a7c16f6 -> ../../pmem1.3

Signed-off-by: Keith Busch <keith.busch@intel.com>
5 years agotest: Fix networkd test for an already running service 9534/head
Martin Pitt [Sun, 8 Jul 2018 15:32:32 +0000 (17:32 +0200)] 
test: Fix networkd test for an already running service

Mount tmpfses over the networkd and resolved config and state
directories, and stop the services beforehand. This ensures that the
test does not mess with an existing networkd/resolved setup. At least
for ethernet setups, this does not sever existing links, so is good
enough for the CI cases we are interested in (QEMU and LXC).

Relax the skip check to only skip the test when trying to run this on
real iron, but start running it in virtual machines now.

This allows us to run the test on Ubuntu 18.04 LTS in CI, which uses
both services by default.

5 years agotest: Reset systemd-resolved.service in networkd test
Martin Pitt [Sun, 8 Jul 2018 17:49:21 +0000 (19:49 +0200)] 
test: Reset systemd-resolved.service in networkd test

Like s-networkd.service itself, it can happen that s-resolved.service
runs into restart limits. Don't enforce a successful call, as on
machines without resolved the unit might not be loaded.

5 years agoman: convert old compile option to meson option
Yu Watanabe [Mon, 9 Jul 2018 04:41:10 +0000 (13:41 +0900)] 
man: convert old compile option to meson option

5 years agohwdb: add accelerometer mount matrix for Umax VisionBook 10Wi Plus
Martin Sobotka [Fri, 6 Jul 2018 22:29:43 +0000 (00:29 +0200)] 
hwdb: add accelerometer mount matrix for Umax VisionBook 10Wi Plus

5 years agosd-bus(3): synchronize the list with reality
Zbigniew Jędrzejewski-Szmek [Sat, 7 Jul 2018 16:38:06 +0000 (18:38 +0200)] 
sd-bus(3): synchronize the list with reality

Use <literallayout> to keep each reference on a separate line. With all the
pages jumbled together into a paragraph, it is quite hard to find anything in
that list.

Also add the missing pages to the list. And remove the nonexistent ones — not
much point in advertisting pages that haven't been written yet.

5 years agonetwork/link: Fix logic error in matching devices by MAC
Dave Reisner [Sat, 7 Jul 2018 09:39:01 +0000 (05:39 -0400)] 
network/link: Fix logic error in matching devices by MAC

Prior to this commit, a .link file with a [Match] section containing
MACAddress= would match any device without a MAC. This restores the
matching logic prior to e90d037.

5 years agohwdb: Add accelerometer orientation quirk for Asus TP200SA
faizalluthfi [Fri, 6 Jul 2018 13:17:52 +0000 (20:17 +0700)] 
hwdb: Add accelerometer orientation quirk for Asus TP200SA

5 years agosystemctl: make variable which stores environment variable constant 9462/head
Yu Watanabe [Thu, 28 Jun 2018 13:31:47 +0000 (22:31 +0900)] 
systemctl: make variable which stores environment variable constant

5 years agopager: split $PAGER or $SYSTEMD_PAGER and use execvp()
Yu Watanabe [Thu, 28 Jun 2018 09:21:39 +0000 (18:21 +0900)] 
pager: split $PAGER or $SYSTEMD_PAGER and use execvp()

This makes pager_open() correctly handle e.g. PAGER='  ' or PAGER=' cat '.

5 years agostrv: make strv_split() accept empty string
Yu Watanabe [Thu, 28 Jun 2018 09:18:55 +0000 (18:18 +0900)] 
strv: make strv_split() accept empty string

5 years agoshow-status: add newline to ephemeral messages
Tomsod M [Sun, 20 May 2018 15:58:58 +0000 (18:58 +0300)] 
show-status: add newline to ephemeral messages

Fixes #6712.  The newline is later reversed, naturally.

5 years agocore/kmod-setup: restore comments
Zbigniew Jędrzejewski-Szmek [Fri, 6 Jul 2018 09:51:04 +0000 (11:51 +0200)] 
core/kmod-setup: restore comments

They were removed in 7491e6e7c5fcb3c445a0656a440bd1551adb6ba1, but the
original version is more informative. Let's add them back.

5 years agoman: Mention that paths in unit files must be fully normalized.
Alexander Kurtz [Thu, 5 Jul 2018 15:06:54 +0000 (17:06 +0200)] 
man: Mention that paths in unit files must be fully normalized.

Related to issues #9107 and #9498 and PRs #9149 and #9157.

5 years agoMerge pull request #9506 from evverx/asan-wrapper
Zbigniew Jędrzejewski-Szmek [Thu, 5 Jul 2018 16:14:00 +0000 (18:14 +0200)] 
Merge pull request #9506 from evverx/asan-wrapper

tests: add a wrapper for when systemd is built with ASAN

5 years agojournal: store the original timestamp as SYSLOG_TIMESTAMP= 9346/head
Zbigniew Jędrzejewski-Szmek [Wed, 4 Jul 2018 22:17:55 +0000 (00:17 +0200)] 
journal: store the original timestamp as SYSLOG_TIMESTAMP=

This is useful if someone wants to recreate the original syslog datagram. We
already include timestamp information as _SOURCE_REALTIME_TIMESTAMP=, and in
normal use that timestamp, converted back to the form used by syslog
(Mth dd HH:MM:SS) would usually give the value. But there are various
circumstances where this might not be true. Most obviously, if the datagram is
sent a bit later after being prepared, the time is rounded to the nearest
second, and it might be off. This is especially bad around New Year when the
syslog timestamp wraps around. Then the same timezone and locale need to be
used to recreate the original timestamp. In the end doing this reliably is
complicated, and it seems much easier to just unconditionally include the
original timestamp.

If the original timestamp cannot be located, we store the full log line.
This way, it should be always possible to recreate the original input.

Example:
MESSAGE=x
SYSLOG_TIMESTAMP=Sep 15 15:07:58
SYSLOG_RAW
^]^@^@^@^@^@^@^@<13>Sep 15 15:07:58 HOST: x^@y
_PID=3318
_SOURCE_REALTIME_TIMESTAMP=1530743976393553

Fixes #2398.

5 years agosystemctl: fix assert for failed mktime conversion
Zbigniew Jędrzejewski-Szmek [Wed, 4 Jul 2018 21:54:43 +0000 (23:54 +0200)] 
systemctl: fix assert for failed mktime conversion

mktime returns -1 on error, so checking for != 0 is not useful.

5 years agojournal: store the original syslog input as SYSLOG_RAW=
Zbigniew Jędrzejewski-Szmek [Fri, 8 Jun 2018 11:52:22 +0000 (13:52 +0200)] 
journal: store the original syslog input as SYSLOG_RAW=

This allows the original stream to be recreated and/or verified. The new field
is written if any stripping was done or if the input message contained embeded
NULs.

$ printf '<13>Sep 15 15:07:58 HOST: x\0y' | nc -w1 -u -U /run/systemd/journal/dev-log

$ journalctl -o json-pretty ...
{
  ...
  "MESSAGE" : "x",
  "SYSLOG_RAW" : [ 60, 49, 51, 62, 83, 101, 112, 32, 49, 53, 32, 49, 53, 58, 48, 55, 58, 53, 56, 32, 72, 79, 83, 84, 58, 32, 120, 0, 121 ]
}

$ journalctl -o export ... | cat -v
...
MESSAGE=x
SYSLOG_RAW
^]^@^@^@^@^@^@^@<13>Sep 15 15:07:58 HOST: x^@y

This mostly fixes #4863.

5 years agojournal: optimize the common case where whitespace stripping is not needed
Zbigniew Jędrzejewski-Szmek [Fri, 8 Jun 2018 09:41:08 +0000 (11:41 +0200)] 
journal: optimize the common case where whitespace stripping is not needed

If we can just use the original data, let's do that.

5 years agoman: fix typo
Zbigniew Jędrzejewski-Szmek [Wed, 4 Jul 2018 08:53:21 +0000 (10:53 +0200)] 
man: fix typo

5 years agotests: redirect ASAN reports on journald to a file 9506/head
Evgeny Vereshchagin [Tue, 3 Jul 2018 19:29:42 +0000 (19:29 +0000)] 
tests: redirect ASAN reports on journald to a file

Otherwise, they will end up in /dev/null.

5 years agotests: add a wrapper for when systemd is built with ASAN
Evgeny Vereshchagin [Tue, 3 Jul 2018 03:25:53 +0000 (03:25 +0000)] 
tests: add a wrapper for when systemd is built with ASAN

5 years agoMerge pull request #9490 from keszybz/document-sd_message_read
Lennart Poettering [Tue, 3 Jul 2018 14:56:49 +0000 (16:56 +0200)] 
Merge pull request #9490 from keszybz/document-sd_message_read

Document sd_bus_message_read

5 years agoMerge pull request #9489 from keszybz/copyright-removal-3
Lennart Poettering [Tue, 3 Jul 2018 14:55:01 +0000 (16:55 +0200)] 
Merge pull request #9489 from keszybz/copyright-removal-3

Copyright header removal, part 3 (or 4?)

5 years agorpm: emit warning when macro with typo is used
Zbigniew Jędrzejewski-Szmek [Tue, 3 Jul 2018 13:40:53 +0000 (15:40 +0200)] 
rpm: emit warning when macro with typo is used

Follow-up for a6bb550458. Suggested by @ignatenkobrain.

$ rpmbuild --eval %_environmentdir
/usr/lib/environment.d
$ rpmbuild --eval %_environmnentdir
warning: Use %_environmentdir instead
/usr/lib/environment.d

5 years agoMerge pull request #9417 from Conan-Kudo/rpm-environmentdir-typo
Zbigniew Jędrzejewski-Szmek [Tue, 3 Jul 2018 13:36:15 +0000 (15:36 +0200)] 
Merge pull request #9417 from Conan-Kudo/rpm-environmentdir-typo

rpm: Fix typo in %_environmentdir

5 years agoconf-parser,login: logs description of error in parsing size
Yu Watanabe [Thu, 28 Jun 2018 05:05:39 +0000 (14:05 +0900)] 
conf-parser,login: logs description of error in parsing size

5 years agoman: add missing <option> tag
Lucas Werkmeister [Tue, 3 Jul 2018 12:11:43 +0000 (14:11 +0200)] 
man: add missing <option> tag

One mention of --user was missing the surrounding <option> tag, making
the table look inconsistent (though the inconsistency is less obvious
after the reordering in 709f4c472c, since the four specifiers mentioning
the --user option are no longer immediately adjacent).

5 years agotest: fix networkd-test.py rate limiting and dynamic user
Martin Pitt [Mon, 2 Jul 2018 20:26:31 +0000 (22:26 +0200)] 
test: fix networkd-test.py rate limiting and dynamic user

 - Reset systemd-networkd.service before each test run, to avoid running
   into restart limits.
 - Our networkd-test-router.service unit needs to run as root and thus
   can't use `User=`; but networkd still insists on the
   `systemd-network` system user to exist, so create it.

5 years agoman: document sd_bus_read(), add more about sd_bus_read_basic() 9490/head
Zbigniew Jędrzejewski-Szmek [Mon, 2 Jul 2018 23:11:11 +0000 (01:11 +0200)] 
man: document sd_bus_read(), add more about sd_bus_read_basic()

5 years agoseccomp: add swapcontext into @process for ppc32
Lion Yang [Mon, 2 Jul 2018 20:58:01 +0000 (04:58 +0800)] 
seccomp: add swapcontext into @process for ppc32

There are some modern programming languages use userspace context switches
to implement coroutine features. PowerPC (32-bit) needs syscall "swapcontext" to get
contexts or switch between contexts, which is special.

Adding this rule should fix #9485.

5 years agotree-wide: add a space after (void)
Yu Watanabe [Tue, 3 Jul 2018 05:36:15 +0000 (14:36 +0900)] 
tree-wide: add a space after (void)

5 years agoresolved: fix typo in log message
Zbigniew Jędrzejewski-Szmek [Mon, 2 Jul 2018 21:13:43 +0000 (23:13 +0200)] 
resolved: fix typo in log message

Follow-up for cc7d50a5714bc810af51b0c55be12b4f55acc089.

5 years agoman: use the same markup for "ap" everywhere
Zbigniew Jędrzejewski-Szmek [Mon, 2 Jul 2018 21:21:04 +0000 (23:21 +0200)] 
man: use the same markup for "ap" everywhere

5 years agotree-wide: drop some leftover header for Lennart Poettering 9489/head
Zbigniew Jędrzejewski-Szmek [Mon, 2 Jul 2018 23:27:02 +0000 (01:27 +0200)] 
tree-wide: drop some leftover header for Lennart Poettering

Follow-up for 0c697941389b7379c4471bc0a067ede02814bc57.

5 years agojournald: drop copyright headers for Sebastian Thorarensen
Zbigniew Jędrzejewski-Szmek [Mon, 2 Jul 2018 23:24:45 +0000 (01:24 +0200)] 
journald: drop copyright headers for Sebastian Thorarensen

For #9320.

5 years agoman: drop mode line in file headers
Zbigniew Jędrzejewski-Szmek [Mon, 2 Jul 2018 21:15:39 +0000 (23:15 +0200)] 
man: drop mode line in file headers

This is already included in .dir-locals, so we don't need it
in the files themselves.

5 years agoAdd IPVLAN= to systemd.network man page (#9480)
mal [Mon, 2 Jul 2018 12:31:58 +0000 (08:31 -0400)] 
Add IPVLAN= to systemd.network man page (#9480)

Required and seems to work in 238.133

5 years agotests: up the image size a little, use twice that size with STRIP_BINARIES=no
Evgeny Vereshchagin [Sat, 30 Jun 2018 05:19:01 +0000 (05:19 +0000)] 
tests: up the image size a little, use twice that size with STRIP_BINARIES=no

to make sure that there's enough room for unstripped binaries.

5 years agosd-bus: publicize sd_bus_message_readv()
Violet Halo [Fri, 15 Jun 2018 08:18:07 +0000 (01:18 -0700)] 
sd-bus: publicize sd_bus_message_readv()

The D-Bus library supplies a va_list variant of
`sd_bus_message_append()` called `sd_bus_message_appendv()`,
but failed to provide a va_list variant of its opposite,
`sd_bus_message_read()`. This commit publicizes a previously static
function as `sd_bus_message_readv()`.

5 years agotree-wide: use instead of #ifdef for HAVE_*
Yu Watanabe [Fri, 29 Jun 2018 07:26:49 +0000 (16:26 +0900)] 
tree-wide: use  instead of #ifdef for HAVE_*

5 years agoresolve: update log message
Yu Watanabe [Thu, 28 Jun 2018 14:57:22 +0000 (23:57 +0900)] 
resolve: update log message

Follow-up for f43580f17d9977ea330deacc8931982e41a49abf.

5 years agoMerge pull request #9468 from yuwata/small-cleanups
Lennart Poettering [Fri, 29 Jun 2018 09:35:57 +0000 (11:35 +0200)] 
Merge pull request #9468 from yuwata/small-cleanups

small fixes and cleanups for comments

5 years agoUse #if instead of #ifdef for ENABLE_GSHADOW
ChenQi1989 [Fri, 29 Jun 2018 06:54:07 +0000 (06:54 +0000)] 
Use #if instead of #ifdef for ENABLE_GSHADOW

ENABLE_GSHADOW is defined to be 0 or 1. So #if should be used instead of #ifdef.

5 years agoAdd accel mount matrix for BayTrail-based tablets by DEXP
RussianNeuroMancer [Wed, 27 Jun 2018 16:32:19 +0000 (00:32 +0800)] 
Add accel mount matrix for BayTrail-based tablets by DEXP

This commit adds accel mount matrix for DEXP Ursus 10XW and Z110i tablets. In current state (*svn*DEXP*:*pn*DEXPOEM*) it will apply to many (if not almost all) BayTrail-based tablets with Windows by DEXP (with same DMI strings) but this expected to cause no (or very little) harm as this devices is mostly very similar with slight difference.

However, if correction of this quirk becomes necessary in the future, this DMI strings could be used to distinguish 10XW and Z110i from other tablets by DEXP.

DEXP Ursus 10XW: dmi:bvnTechvisionHASHVersion96AC8868:bvr5.6.5:bd12/26/2014:svnDEXP:pnDEXPOEM:pvr1.0:rvnDEXP:rnDEXPOEM:rvr1.0:cvnToBeFilledByO.E.M.:ct3:cvrToBeFilledByO.E.M.:
DEXP Ursus Z110i Apollo: dmi:bvnTechvisionHASHVersion1DE28747:bvr5.6.5:bd03/14/2015:svnDEXP:pnDEXPOEM:pvr1.0:rvnDEXP:rnDEXPOEM:rvr1.0:cvnToBeFilledByO.E.M.:ct3:cvrToBeFilledByO.E.M.:

5 years agoman: add missing parentheses 9468/head
Yu Watanabe [Fri, 29 Jun 2018 03:40:27 +0000 (12:40 +0900)] 
man: add missing parentheses

5 years agobus-util: update comment
Yu Watanabe [Fri, 29 Jun 2018 03:35:36 +0000 (12:35 +0900)] 
bus-util: update comment

Originally, request_name_handler_may_reload_dbus() was written for
timesyncd. But now it is also called by networkd or resolved.

5 years agotree-wide: drop double newline
Yu Watanabe [Fri, 29 Jun 2018 02:02:17 +0000 (11:02 +0900)] 
tree-wide: drop double newline

5 years agotree-wide: drop empty comments
Yu Watanabe [Fri, 29 Jun 2018 02:00:30 +0000 (11:00 +0900)] 
tree-wide: drop empty comments

5 years agotree-wide: drop empty lines in the begining of comments
Yu Watanabe [Fri, 29 Jun 2018 01:50:23 +0000 (10:50 +0900)] 
tree-wide: drop empty lines in the begining of comments

5 years agonetwork: update log message
Yu Watanabe [Mon, 25 Jun 2018 12:04:22 +0000 (21:04 +0900)] 
network: update log message

Closes #9396.

5 years agobus-util: drop unnecessary !!
Yu Watanabe [Mon, 25 Jun 2018 07:19:32 +0000 (16:19 +0900)] 
bus-util: drop unnecessary !!

5 years agoMerge pull request #9422 from yuwata/conf-files
Lennart Poettering [Thu, 28 Jun 2018 08:17:54 +0000 (10:17 +0200)] 
Merge pull request #9422 from yuwata/conf-files

cleanups for default conf files

5 years agotree-wide: use 'signed int' instead of 'int' for bit field variables
Yu Watanabe [Wed, 27 Jun 2018 06:46:43 +0000 (15:46 +0900)] 
tree-wide: use 'signed int' instead of 'int' for bit field variables

Suggested by LGTM: https://lgtm.com/rules/1506024027114/

5 years agoMerge pull request #9452 from evverx/coverity.sh
Lennart Poettering [Thu, 28 Jun 2018 08:07:59 +0000 (10:07 +0200)] 
Merge pull request #9452 from evverx/coverity.sh

 coverity.sh: use a comma to separate module names

5 years agoresolve: warn when our stub listener is disabled but resolv.conf uses it
Yu Watanabe [Thu, 28 Jun 2018 06:01:28 +0000 (15:01 +0900)] 
resolve: warn when our stub listener is disabled but resolv.conf uses it

Closes #9450.

5 years agomeson: do not compare objects of different types
Yu Watanabe [Thu, 28 Jun 2018 07:09:04 +0000 (16:09 +0900)] 
meson: do not compare objects of different types

This fixes the following warning:
```
meson.build:1140: WARNING: Trying to compare values of different types (DependencyHolder, list) using !=.
The result of this is undefined and will become a hard error in a future Meson release.
```

Follow-up for f02582f69fe1e7663a87ba80bd4f90d5d23ee75f(#9410).

5 years agosd-bus: stop using the result of an assignment as an operand of &&
Evegeny Vereshchagin [Tue, 26 Jun 2018 02:32:44 +0000 (02:32 +0000)] 
sd-bus: stop using the result of an assignment as an operand of &&

This makes OBJECT_PATH_FOREACH_PREFIX consistent with PATH_FOREACH_PREFIX
and also fixes 7 alerts reported by LGTM at
https://lgtm.com/projects/g/systemd/systemd/snapshot/ac0a08700344a5690803df8dd80e8bb5013184a5/files/src/libsystemd/sd-bus/bus-objects.c?sort=name&dir=ASC&mode=heatmap&showExcluded=true#V1383

5 years agocore: tiny comment fix
Lennart Poettering [Wed, 27 Jun 2018 18:02:49 +0000 (20:02 +0200)] 
core: tiny comment fix

5 years agosummary: update nspawn description string a bit
Lennart Poettering [Wed, 27 Jun 2018 17:59:45 +0000 (19:59 +0200)] 
summary: update nspawn description string a bit

nspawn as it is now is a generally useful tool, hence let's drop the
comments about it being useful for debug and so on only.

The new wording just makes the first sentence of the main page also the
summary.

5 years agosleep: fix one more printf format of a fiemap field
Filipe Brandenburger [Wed, 27 Jun 2018 16:19:33 +0000 (09:19 -0700)] 
sleep: fix one more printf format of a fiemap field

Use PRIu64 constant to get the format right on LP-64 architectures,
cast to (uint64_t) to solve incompatibility of __u64.

This was missed in ad4bc3352285f467f4ffa03c3171b19fa0a8758d, so fix it
with this follow up.

5 years agobasic: add missing comma in raw_clone assembly for sparc
Mike Gilbert [Wed, 27 Jun 2018 14:36:50 +0000 (10:36 -0400)] 
basic: add missing comma in raw_clone assembly for sparc

Fixes: 96f64eb5741b157f26a9089816fdd992e959792e
Closes: https://github.com/systemd/systemd/issues/9444
5 years agocryptsetup: Add dependency on loopback setup to generated units
Lorenz Hübschle-Schneider [Tue, 26 Jun 2018 17:41:30 +0000 (19:41 +0200)] 
cryptsetup: Add dependency on loopback setup to generated units

For loopback volumes, the generated unit needs to depend on
systemd-tmpfiles-setup-dev.service to ensure that loopback
support is loaded.

Fixes #9308