diff options
author | David Herrmann <dh.herrmann@googlemail.com> | 2015-11-27 20:26:33 +0100 |
---|---|---|
committer | David Herrmann <dh.herrmann@googlemail.com> | 2015-11-27 20:26:33 +0100 |
commit | 564c44436cf64adc7a9eff8c17f386899194a893 (patch) | |
tree | 9c71d044032b117f84fd804e72def2236b7321b3 /src/libsystemd-network/sd-ipv4ll.c | |
parent | e900a8467962da3483dd7b62cc7f41043a4584cf (diff) | |
parent | 9ead3519c54b6d1b79b35541873b5cf7c8b3a7d3 (diff) |
Merge pull request #2052 from poettering/export-cleanup
Make gcc cleanup helper calls public in most of our sd-xyz APIs
Diffstat (limited to 'src/libsystemd-network/sd-ipv4ll.c')
-rw-r--r-- | src/libsystemd-network/sd-ipv4ll.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/src/libsystemd-network/sd-ipv4ll.c b/src/libsystemd-network/sd-ipv4ll.c index 30a7ef5785..db6cf22aaa 100644 --- a/src/libsystemd-network/sd-ipv4ll.c +++ b/src/libsystemd-network/sd-ipv4ll.c @@ -28,7 +28,6 @@ #include "sd-ipv4ll.h" #include "alloc-util.h" -#include "event-util.h" #include "in-addr-util.h" #include "list.h" #include "random-util.h" @@ -41,7 +40,7 @@ #define IPV4LL_NETMASK 0xFFFF0000L #define IPV4LL_DONT_DESTROY(ll) \ - _cleanup_ipv4ll_unref_ _unused_ sd_ipv4ll *_dont_destroy_##ll = sd_ipv4ll_ref(ll) + _cleanup_(sd_ipv4ll_unrefp) _unused_ sd_ipv4ll *_dont_destroy_##ll = sd_ipv4ll_ref(ll) struct sd_ipv4ll { unsigned n_ref; @@ -86,13 +85,10 @@ sd_ipv4ll *sd_ipv4ll_unref(sd_ipv4ll *ll) { return NULL; } -DEFINE_TRIVIAL_CLEANUP_FUNC(sd_ipv4ll*, sd_ipv4ll_unref); -#define _cleanup_ipv4ll_unref_ _cleanup_(sd_ipv4ll_unrefp) - static void ipv4ll_on_acd(sd_ipv4acd *ll, int event, void *userdata); int sd_ipv4ll_new(sd_ipv4ll **ret) { - _cleanup_ipv4ll_unref_ sd_ipv4ll *ll = NULL; + _cleanup_(sd_ipv4ll_unrefp) sd_ipv4ll *ll = NULL; int r; assert_return(ret, -EINVAL); |