| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
| |
`org.freedesktop.DBus.ObjectManager` should only be emitted if
object in question has ObjectManager attached.
|
| |
|
|
|
|
|
|
|
|
|
| |
Objects without ObjectManager should not have
`org.freedesktop.DBus.ObjectManager` interface.
Object with ObjectManager should do.
Also added ASSERT_SE_NONNEG and ASSERT_NONNEG macros.
|
|\
| |
| | |
network: fix wlan interface handling when its RF is killed
|
| | |
|
| | |
|
| | |
|
| |
| |
| |
| |
| | |
This also introduces sd_nfnl_message_new() which can be also used for
non-nftables subsystems.
|
| | |
|
| |
| |
| |
| |
| |
| |
| | |
And this makes the new merged function `sd_nfnl_nft_message_new_setelems()`
not open container, as containers should be opened and closed in the
same function in general. Otherwise, it is hard to understand which
level we are in the nested attribute tree.
|
| | |
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| | |
- rename family -> nfproto, and other arguments,
- check specified nfproto,
- change type of several function arguments that specify data length,
- add several assertions,
- drop unnecessary headers.
|
| | |
|
|/ |
|
|\
| |
| | |
Replace __sync intrinsics with __atomic
|
| | |
|
|\ \
| | |
| | | |
sd-event: tiny cleanups
|
| | | |
|
| |/
| |
| |
| |
| | |
The function `source_io_unregister()` will be anyway called in
`source_disconnect()`.
|
|/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Currently, if journald coredumps, the coredump is written to
/var/lib/systemd/coredump but the coredump metadata is not written
to the journal meaning we can't find out about the coredump's
existence via the journal. This means that coredumpctl can't be
used to work with journald coredumps, as well as any other tools
that rely on journald to know about coredumps.
To solve the issue, let's have systemd-coredump try to write
systemd-journald coredump metadata to the journal. We have to be
careful though, since if journald coredumps, there's no active
reader on the receive end of the journal socket, so we have to make
sure we don't deadlock trying to write to the socket. To avoid the
deadlock, we put the socket in nonblocking mode before trying to
write to it.
|
|
|
|
| |
Fixes #24003.
|
|\
| |
| | |
sd-device: send udev database version
|
| |
| |
| |
| |
| |
| |
| | |
Otherwise, sd-device object received through sd-device-monitor does not
show current tags.
Fixes #23799.
|
| |
| |
| |
| |
| |
| | |
In most cases, it is not necessary to call them without retrieving
result. But, most of other getter functions for sd-device can take NULL.
Let's follow the way for consistency.
|
| | |
|
|\ \
| | |
| | | |
sd-device: do not return -ENOENT by sd_device_get_is_initialized()
|
| | | |
|
| |/ |
|
|/
|
|
|
| |
Add sizes for some uses of NETLINK_TYPE_IN_ADDR and NETLINK_TYPE_ETHER_ADDR
types.
|
|
|
|
|
|
|
| |
Currently, both these functions don't return 0 if we're at HEAD/TAIL
and move in the corresponding direction. Let's fix that.
Replaces #23480
|
|\
| |
| | |
basic/list: drop LIST_IS_EMPTY
|
| | |
|
| | |
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This was a trivial wrapper that didn't provide any added value. With more
complicated structures like strvs, hashmaps, sets, and arrays, it is possible
to have an empty container. But in case of a list, the list is empty only when
the head is missing.
Also, we generally want the positive condition, so we replace many
if (!LIST_IS_EMPTY(x)) with just if (x).
|
| |
| |
| |
| |
| |
| |
| |
| | |
We now have a local implementation in string-util-fundamental.c, but
it's useful at a lot of other places, hence let's give it a more
expressive name and share it across the tree.
Follow-up for: 8d9156660d6958c8d63b1d44692968f1b5d33920
|
| | |
|
|\ \
| | |
| | | |
sd-id128: avoid an unnecessary function call in inline helper
|
| |/
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
In function 'sd_id128_equal',
inlined from 'journal_file_verify' at ../src/libsystemd/sd-journal/journal-verify.c:1047:29:
../src/systemd/sd-id128.h:119:43: error: 'entry_boot_id.qwords[0]' may be used uninitialized [-Werror=maybe-uninitialized]
119 | return a.qwords[0] == b.qwords[0] && a.qwords[1] == b.qwords[1];
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../src/libsystemd/sd-journal/journal-verify.c: In function 'journal_file_verify':
../src/libsystemd/sd-journal/journal-verify.c:823:20: note: 'entry_boot_id.qwords[0]' was declared here
823 | sd_id128_t entry_boot_id;
| ^~~~~~~~~~~~~
cc1: all warnings being treated as errors
entry_boot_id is only used when entry_monotonic_set has been set, and that's
only done in one place where entry_boot_id is also initalized.
|
| |
| |
| |
| | |
See previous commit for justification.
|
| |
| |
| |
| |
| |
| | |
We have RxBufferSize= and TxBufferSize= in .link files. Let's use the same
abbreviation here. OTOH, "inc" could be short for "increment" or "increase",
let's avoid that.
|
| | |
|
| |
| |
| |
| | |
Also, document that NULL is allowed.
|
| |
| |
| |
| |
| |
| | |
Same story as before: disabling a non-existent event source shouldn't
need to be guarded by an if. I retained the wrapper so that that we don't
have to say SD_EVENT_OFF in the many places where this is called.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This is a natural use case, and instead of defining a wrapper to do this
for us, let's just make this part of the API. Calling with NULL was not
allowed, so this is not a breaking change to the interface.
(After sd_event_source_is_enabled was originally added, we introduced
sd_event_source_disable_unref() and other similar functions which accept
NULL. So not accepting NULL here is likely to confuse people. Let's just
make the API usable with minimal fuss.)
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Before, sd_netlink_message_read() expected to fill a buffer completely,
and would return -EIO if the attribute being read was shorter than the
buffer. This means that the function can be used to "peek" into attributes
(by specifying a short buffer to just read part of the attribute), but
cannot be used to read something into a union without knowing beforehand
which specific field in the union is being filled. That latter operation
seems more useful (messages are short, so we don't really need to do partial
reads), so let's allow reads that don't fill the output buffer completely.
|
| |
| |
| |
| |
| | |
The same story as before: it's a useful helper, other uses of the library
are likely to find it useful.
|
| |
| |
| |
| |
| |
| |
| |
| | |
We find this function useful in our code, so no reason not to export it.
I changed the order of last two words in the name to match the arguments.
(With "equal_string" I expected sd_id128_t first, string second, but in
actual use, the second argument is usually a long constant so it's nice
to keep this order of arguments.)
|