]> git.ipfire.org Git - thirdparty/systemd.git/commit
json: don't assert() if we add a NULL element via json_variant_set_field()
authorLennart Poettering <lennart@poettering.net>
Thu, 25 Nov 2021 09:30:45 +0000 (10:30 +0100)
committerLennart Poettering <lennart@poettering.net>
Thu, 25 Nov 2021 13:21:54 +0000 (14:21 +0100)
commite2c7efd3293c6a14cd6d5baf8e0898da9a5c6d96
treecd5863e9e9fafef2ca582b166d9174db2a77f1a2
parentfb0321029cf844d0e2621bf45bd6527666dc2bc8
json: don't assert() if we add a NULL element via json_variant_set_field()

The rest of our JSON code tries hard to magically convert NULL inputs
into "null" JSON objects, let's make sure this also works with
json_variant_set_field().
src/shared/json.c
src/test/test-json.c