Systemd/src/machine
Lennart Poettering ae2a15bc14 macro: introduce TAKE_PTR() macro
This macro will read a pointer of any type, return it, and set the
pointer to NULL. This is useful as an explicit concept of passing
ownership of a memory area between pointers.

This takes inspiration from Rust:

https://doc.rust-lang.org/std/option/enum.Option.html#method.take

and was suggested by Alan Jenkins (@sourcejedi).

It drops ~160 lines of code from our codebase, which makes me like it.
Also, I think it clarifies passing of ownership, and thus helps
readability a bit (at least for the initiated who know the new macro)
2018-03-22 20:21:42 +01:00
..
image-dbus.c tree-wide: introduce new safe_fork() helper and port everything over 2017-12-25 11:48:21 +01:00
image-dbus.h machined: port machined's bus APIs to use new image metadata API 2017-11-20 16:43:15 +01:00
machine-dbus.c macro: introduce TAKE_PTR() macro 2018-03-22 20:21:42 +01:00
machine-dbus.h Add SPDX license identifiers to source files under the LGPL 2017-11-19 19:08:15 +01:00
machine.c machined: change check_gc to may_gc everywhere 2018-02-15 14:09:40 +01:00
machine.h machined: change check_gc to may_gc everywhere 2018-02-15 14:09:40 +01:00
machinectl.c bus-util: introduce bus_message_print_all_properties() 2018-03-20 00:44:37 +09:00
machined-dbus.c fixed 3 occurences of 'Failed top open' (#8349) 2018-03-04 21:12:45 +09:00
machined.c machined: change check_gc to may_gc everywhere 2018-02-15 14:09:40 +01:00
machined.h Add SPDX license identifiers to source files under the LGPL 2017-11-19 19:08:15 +01:00
meson.build meson: drop unnecessary "transformation" of policy files 2018-02-16 13:01:12 +01:00
operation.c Add SPDX license identifiers to source files under the LGPL 2017-11-19 19:08:15 +01:00
operation.h Add SPDX license identifiers to source files under the LGPL 2017-11-19 19:08:15 +01:00
org.freedesktop.machine1.conf machined: port machined's bus APIs to use new image metadata API 2017-11-20 16:43:15 +01:00
org.freedesktop.machine1.policy meson: drop unnecessary "transformation" of policy files 2018-02-16 13:01:12 +01:00
org.freedesktop.machine1.service Add SPDX license headers to various assorted files 2017-11-19 19:08:15 +01:00
test-machine-tables.c Add SPDX license identifiers to source files under the LGPL 2017-11-19 19:08:15 +01:00