logo
Free, unlimited AI code reviews that run on commit
git-lrc git-lrc GitHub Install Now We'd appreciate a star git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt

mdex_del - delete an entry from a multicast index

Description

       The  mdex_del  function  deletes an entry from the multicast index mdex using hash (of length hashlen) as
       the key.  If no matching entry is found in the index, -1 is returned and errno is set to ENOENT.

       hashlen can be shorter than the full length of the hash stored with mdex_put(3) and will delete the first
       entry matching the truncated hash.  This allows us to store the full 32 byte hash in the index, but still
       match against the truncated hash derived from, say, the 14 bytes of an IPv6 multicast group address.

Errors

EINVAL Invalid argument. Both mdex and hash are required (not NULL), and hashlen > 0.

       ENOENT No entry found matching hash.

Library

       Librecast library (liblibrecast, -llibrecast)

Name

       mdex_del - delete an entry from a multicast index

Return Value

mdex_put() returns zero on success.  On error, -1 is returned, and errno is set to indicate the error.

See Also

mdex_init(3), mdex_free(3), mdex_get(3), mdex_put(3), lc_share(3)

LIBRECAST                                          2023-06-20                                        MDEX_DEL(3)

Synopsis

#include<librecast/mdex.h>intmdex_del(mdex_t*mdex,unsignedchar*hash,size_thashlen);

       Compile and link with -llibrecast.

See Also