Logo Search packages:      
Sourcecode: libnl2 version File versions  Download package

int rtnl_cls_delete ( struct nl_sock *  sk,
struct rtnl_cls *  cls,
int  flags 

Delete a classifier

  • sk Netlink socket.
  • cls classifier to delete
  • flags additional netlink message flags
Builds a netlink message by calling rtnl_cls_build_delete_request(), sends the request to the kernel and waits for the next ACK to be received and thus blocks until the request has been processed.

0 on sucess or a negative error if an error occured.

Definition at line 255 of file cls.c.

References nl_send_auto_complete(), nl_wait_for_ack(), nlmsg_free(), and rtnl_cls_build_delete_request().

      struct nl_msg *msg;
      int err;
      if ((err = rtnl_cls_build_delete_request(cls, flags, &msg)) < 0)
            return err;
      err = nl_send_auto_complete(sk, msg);
      if (err < 0)
            return err;

      return nl_wait_for_ack(sk);

Generated by  Doxygen 1.6.0   Back to index