diff options
author | Eduardo Habkost <ehabkost@redhat.com> | 2020-11-11 13:38:22 -0500 |
---|---|---|
committer | Eduardo Habkost <ehabkost@redhat.com> | 2020-12-15 10:02:07 -0500 |
commit | f0e34a06f6580e666a1f49d1b8315adf1d587c43 (patch) | |
tree | 9101e40233c5f085f648955d1f3983dc4c31aea8 /net/filter-rewriter.c | |
parent | 6d11ea6d8e5ad0ba3766755cc23a1392ae321433 (diff) |
netfilter: Use class properties
Instance properties make introspection hard and are not shown by
"-object ...,help". Convert them to class properties.
Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
Message-Id: <20201111183823.283752-12-ehabkost@redhat.com>
Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
Diffstat (limited to 'net/filter-rewriter.c')
-rw-r--r-- | net/filter-rewriter.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/net/filter-rewriter.c b/net/filter-rewriter.c index e063a818b7..fc0e64c45b 100644 --- a/net/filter-rewriter.c +++ b/net/filter-rewriter.c @@ -418,15 +418,16 @@ static void filter_rewriter_init(Object *obj) s->vnet_hdr = false; s->failover_mode = FAILOVER_MODE_OFF; - object_property_add_bool(obj, "vnet_hdr_support", - filter_rewriter_get_vnet_hdr, - filter_rewriter_set_vnet_hdr); } static void colo_rewriter_class_init(ObjectClass *oc, void *data) { NetFilterClass *nfc = NETFILTER_CLASS(oc); + object_class_property_add_bool(oc, "vnet_hdr_support", + filter_rewriter_get_vnet_hdr, + filter_rewriter_set_vnet_hdr); + nfc->setup = colo_rewriter_setup; nfc->cleanup = colo_rewriter_cleanup; nfc->receive_iov = colo_rewriter_receive_iov; |