#include <assert.h>
#include <errno.h>
#include <string.h>
#include <libipset/debug.h>
#include <libipset/data.h>
#include <libipset/session.h>
#include <libipset/types.h>
#include <libipset/utils.h>
#include <libipset/errcode.h>
#include <libipset/linux_ip_set_bitmap.h>
#include <libipset/linux_ip_set_hash.h>
#include <libipset/linux_ip_set_list.h>
Macros | |
#define | MATCH_TYPENAME(a, b) STRNEQ(a, b, strlen(b)) |
Functions | |
int | ipset_errcode (struct ipset_session *session, enum ipset_cmd cmd, int errcode) |
ipset_errcode - interpret a kernel error code : session structure : errcode More... | |
#define MATCH_TYPENAME | ( | a, | |
b | |||
) | STRNEQ(a, b, strlen(b)) |
Referenced by ipset_errcode().
int ipset_errcode | ( | struct ipset_session * | session, |
enum ipset_cmd | cmd, | ||
int | errcode | ||
) |
ipset_errcode - interpret a kernel error code : session structure : errcode
Find the error code and print the appropriate error message into the error buffer.
Returns -1.
References ipset_errcode_table::errcode, ipset_err, IPSET_ERR_PRIVATE, IPSET_ERR_TYPE_SPECIFIC, ipset_saved_type(), MATCH_TYPENAME, ipset_errcode_table::message, ipset_type::name, and type.