libnl 3.11.0
nl_cb Struct Reference

Data Fields

nl_recvmsg_msg_cb_t cb_set [NL_CB_TYPE_MAX+1]
 
void * cb_args [NL_CB_TYPE_MAX+1]
 
nl_recvmsg_err_cb_t cb_err
 
void * cb_err_arg
 
int(* cb_recvmsgs_ow )(struct nl_sock *, struct nl_cb *)
 May be used to replace nl_recvmsgs with your own implementation in all internal calls to nl_recvmsgs.
 
int(* cb_recv_ow )(struct nl_sock *, struct sockaddr_nl *, unsigned char **, struct ucred **)
 Overwrite internal calls to nl_recv, must return the number of octets read and allocate a buffer for the received data.
 
int(* cb_send_ow )(struct nl_sock *, struct nl_msg *)
 Overwrites internal calls to nl_send, must send the netlink message.
 
int cb_refcnt
 
enum nl_cb_type cb_active
 indicates the callback that is currently active
 

Detailed Description

Definition at line 9 of file nl-core.h.

Field Documentation

◆ cb_set

nl_recvmsg_msg_cb_t nl_cb::cb_set[NL_CB_TYPE_MAX+1]

Definition at line 11 of file nl-core.h.

◆ cb_args

void* nl_cb::cb_args[NL_CB_TYPE_MAX+1]

Definition at line 12 of file nl-core.h.

◆ cb_err

nl_recvmsg_err_cb_t nl_cb::cb_err

Definition at line 14 of file nl-core.h.

◆ cb_err_arg

void* nl_cb::cb_err_arg

Definition at line 15 of file nl-core.h.

◆ cb_recvmsgs_ow

int(* nl_cb::cb_recvmsgs_ow) (struct nl_sock *, struct nl_cb *)

May be used to replace nl_recvmsgs with your own implementation in all internal calls to nl_recvmsgs.

Definition at line 19 of file nl-core.h.

Referenced by nl_cb_overwrite_recvmsgs(), and nl_recvmsgs_report().

◆ cb_recv_ow

int(* nl_cb::cb_recv_ow) (struct nl_sock *, struct sockaddr_nl *, unsigned char **, struct ucred **)

Overwrite internal calls to nl_recv, must return the number of octets read and allocate a buffer for the received data.

Definition at line 24 of file nl-core.h.

Referenced by nl_cb_overwrite_recv().

◆ cb_send_ow

int(* nl_cb::cb_send_ow) (struct nl_sock *, struct nl_msg *)

Overwrites internal calls to nl_send, must send the netlink message.

Definition at line 31 of file nl-core.h.

Referenced by nl_cb_overwrite_send(), and nl_send().

◆ cb_refcnt

int nl_cb::cb_refcnt

Definition at line 34 of file nl-core.h.

◆ cb_active

enum nl_cb_type nl_cb::cb_active

indicates the callback that is currently active

Definition at line 36 of file nl-core.h.

Referenced by nl_cb_active_type(), and nl_cb_alloc().