summaryrefslogtreecommitdiffstats
path: root/include/libipset/data.h
diff options
context:
space:
mode:
authorOliver Smith <oliver@8.c.9.b.0.7.4.0.1.0.0.2.ip6.arpa>2013-09-22 20:56:35 +0200
committerJozsef Kadlecsik <kadlec@blackhole.kfki.hu>2013-09-23 14:03:58 +0200
commite1cc3d782f3bca89c8d8f2ca6b0fd7885fc91cf8 (patch)
tree2a36ae768373a9afa6f9c8d06c0373bcbb739dbf /include/libipset/data.h
parentf13a2af1f99b4d226231126a7e716635b555df42 (diff)
ipset: Support comments in the userspace library.
This adds support to the userspace portion of ipset for handling ipsets with the comment extension enabled. The library revision has been raised accordingly. Signed-off-by: Oliver Smith <oliver@8.c.9.b.0.7.4.0.1.0.0.2.ip6.arpa> Signed-off-by: Jozsef Kadlecsik <kadlec@blackhole.kfki.hu>
Diffstat (limited to 'include/libipset/data.h')
-rw-r--r--include/libipset/data.h9
1 files changed, 7 insertions, 2 deletions
diff --git a/include/libipset/data.h b/include/libipset/data.h
index 2b6b8cd..b6e75e8 100644
--- a/include/libipset/data.h
+++ b/include/libipset/data.h
@@ -57,6 +57,8 @@ enum ipset_opt {
IPSET_OPT_COUNTERS,
IPSET_OPT_PACKETS,
IPSET_OPT_BYTES,
+ IPSET_OPT_CREATE_COMMENT,
+ IPSET_OPT_ADT_COMMENT,
/* Internal options */
IPSET_OPT_FLAGS = 48, /* IPSET_FLAG_EXIST| */
IPSET_OPT_CADT_FLAGS, /* IPSET_FLAG_BEFORE| */
@@ -87,7 +89,8 @@ enum ipset_opt {
| IPSET_FLAG(IPSET_OPT_NETMASK) \
| IPSET_FLAG(IPSET_OPT_PROBES) \
| IPSET_FLAG(IPSET_OPT_RESIZE) \
- | IPSET_FLAG(IPSET_OPT_SIZE))
+ | IPSET_FLAG(IPSET_OPT_SIZE) \
+ | IPSET_FLAG(IPSET_OPT_CREATE_COMMENT))
#define IPSET_ADT_FLAGS \
(IPSET_FLAG(IPSET_OPT_IP) \
@@ -106,11 +109,13 @@ enum ipset_opt {
| IPSET_FLAG(IPSET_OPT_CADT_FLAGS)\
| IPSET_FLAG(IPSET_OPT_BEFORE) \
| IPSET_FLAG(IPSET_OPT_PHYSDEV) \
- | IPSET_FLAG(IPSET_OPT_NOMATCH))
+ | IPSET_FLAG(IPSET_OPT_NOMATCH) \
+ | IPSET_FLAG(IPSET_OPT_ADT_COMMENT))
struct ipset_data;
extern void ipset_strlcpy(char *dst, const char *src, size_t len);
+extern void ipset_strlcat(char *dst, const char *src, size_t len);
extern bool ipset_data_flags_test(const struct ipset_data *data,
uint64_t flags);
extern void ipset_data_flags_set(struct ipset_data *data, uint64_t flags);