netfilter-devel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [nft PATCH 0/4] libnftables: minor cleanups initalizing nf_sock instance of nft_ctx
@ 2023-07-10  8:45 Thomas Haller
  2023-07-10  8:45 ` [nft PATCH 1/4] libnftables: always initialize netlink socket in nft_ctx_new() Thomas Haller
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: Thomas Haller @ 2023-07-10  8:45 UTC (permalink / raw)
  To: NetFilter; +Cc: Thomas Haller

There is some unnecessary or redundant code in "src/libnftables.c".
Clean up.

This was motivated by an attempt to add a new flag for nft_ctx_new(),
beside NFT_CTX_DEFAULT. The current "if (flags == NFT_CTX_DEFAULT)"
check is an odd usage for flags (because we would want that behavior for
all flags).

Thomas Haller (4):
  libnftables: always initialize netlink socket in nft_ctx_new()
  libnftables: drop unused argument nf_sock from nft_netlink()
  libnftables: inline creation of nf_sock in nft_ctx_new()
  libnftables: drop check for nf_sock in nft_ctx_free()

 src/libnftables.c | 18 +++++-------------
 1 file changed, 5 insertions(+), 13 deletions(-)

-- 
2.41.0


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2023-07-10 16:22 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-07-10  8:45 [nft PATCH 0/4] libnftables: minor cleanups initalizing nf_sock instance of nft_ctx Thomas Haller
2023-07-10  8:45 ` [nft PATCH 1/4] libnftables: always initialize netlink socket in nft_ctx_new() Thomas Haller
2023-07-10  8:45 ` [nft PATCH 2/4] libnftables: drop unused argument nf_sock from nft_netlink() Thomas Haller
2023-07-10  8:45 ` [nft PATCH 3/4] libnftables: inline creation of nf_sock in nft_ctx_new() Thomas Haller
2023-07-10  8:45 ` [nft PATCH 4/4] libnftables: drop check for nf_sock in nft_ctx_free() Thomas Haller
2023-07-10 16:22 ` [nft PATCH 0/4] libnftables: minor cleanups initalizing nf_sock instance of nft_ctx Pablo Neira Ayuso

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).