]> git.ipfire.org Git - thirdparty/systemd.git/commit
sd-varlink: ensure that "any" actually means "any but null"
authorLennart Poettering <lennart@poettering.net>
Mon, 19 Jan 2026 19:06:00 +0000 (20:06 +0100)
committerMike Yuan <me@yhndnzj.com>
Mon, 19 Jan 2026 20:29:38 +0000 (21:29 +0100)
commit799392286ec0797c0a2a1260c444360b47ef36fc
tree704fe22364c05e02190fc4255f43e4e2e145eeab
parent8a5fb3627a1518d2d2ef70919c81448158d64ac0
sd-varlink: ensure that "any" actually means "any but null"

The new "any" type was implemented by accident that it actually meant
"any but null" – unless marked as "any?" in which case it actually meant
truly any, including null. The spec change in
https://github.com/varlink/varlink.github.io/pull/43 otoh suggested that
"any" really means anything, and "any?" apparently too.

I think the implementation in code makes more sense than the spec change
however, hence let's add some checks/tests to ensure the behaviour of
the code is made explicitly and cared for.

I will prep a spec change to make the spec follow the code on this too.

Follow-up for: #39918
src/libsystemd/sd-varlink/sd-varlink-idl.c
src/test/test-varlink-idl.c