From 1759d7ec38637e1eaf009619f463d6b121e23502 Mon Sep 17 00:00:00 2001 From: Jozsef Kadlecsik Date: Wed, 18 Mar 2015 20:58:25 +0100 Subject: Support linking libipset to C++ programs Issue reported by Pavel Odintsov. --- include/libipset/types.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'include/libipset/types.h') diff --git a/include/libipset/types.h b/include/libipset/types.h index c98855e..7f41afc 100644 --- a/include/libipset/types.h +++ b/include/libipset/types.h @@ -86,6 +86,10 @@ struct ipset_type { const char *alias[]; /* name alias(es) */ }; +#ifdef __cplusplus +extern "C" { +#endif + extern int ipset_cache_add(const char *name, const struct ipset_type *type, uint8_t family); extern int ipset_cache_del(const char *name); @@ -107,6 +111,10 @@ extern bool ipset_match_typename(const char *str, const struct ipset_type *t); extern void ipset_load_types(void); +#ifdef __cplusplus +} +#endif + #ifdef TYPE_INCLUSIVE # ifdef _INIT # undef _init -- cgit v1.2.3