From: Frantisek Sumsal Date: Thu, 28 Dec 2023 17:02:26 +0000 (+0100) Subject: coccinelle: add a rule for in_addr_hash_func() X-Git-Tag: v256-rc1~1349^2 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F30689%2Fhead;p=thirdparty%2Fsystemd.git coccinelle: add a rule for in_addr_hash_func() Follow-up for c01a5c0. --- diff --git a/coccinelle/siphash24.cocci b/coccinelle/siphash24.cocci index a9afd90aa60..c577120f7b9 100644 --- a/coccinelle/siphash24.cocci +++ b/coccinelle/siphash24.cocci @@ -4,3 +4,10 @@ expression p, s; @@ - siphash24_compress(&p, sizeof(p), s); + siphash24_compress_typesafe(p, s); + +@@ +union in_addr_union p; +expression f, s; +@@ +- siphash24_compress(&p, FAMILY_ADDRESS_SIZE(f), s); ++ in_addr_hash_func(&p, f, s);