mtype_del_cidr(9)
β¨ NAME β¨
Okay bestie, meet mtype_del_cidr(9) from the Kernel API Manual π«Ά. Its whole vibe is Remove CIDR entry and maintain array integrity. Literally thatβs the job β no cap π
. Think of it as the cleanup bestie that keeps the array looking cute and staying contiguous after a CIDR entry dips out.
π« SYNOPSIS π«
void mtype_del_cidr (struct ip_set *set , struct htype *h , u8 cidr , u8
n );
π ARGUMENTS π
setβ Pointer to theip_setπ«Ά yes, thatip_set.hβ Pointer to thehtype.cidrβ The CIDR prefix length.nβ The index of thenet_prefixarray to removecidrfrom.
π₯ DESCRIPTION π₯
If the CIDR entry count falls to 0, this function performs a "shift-left" operation on all following elements π€. Thatβs the whole point: it ensures that the array remains contiguous and maintains its descending order by CIDR. Iconic behavior, honestly β¨. The vacated slot at the end of the array is zeroed out (cidr=0, count=0) β not me making it empty and tidy, itβs literally in the spec πβ¨.
bestie, this is the βkeep the array cute and contiguousβ era π
π SEE ALSO π
- Kernel file
./net/netfilter/ipset/ip_set_hash_gen.h struct net_prefix(9)struct net_prefixes(9)mtype_add_cidr(9)
β xoxo, sourced from ./net/netfilter/ipset, dated October 2026 ππ
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms