summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorPablo Neira Ayuso <pablo@netfilter.org>2012-03-26 21:39:29 +0200
committerPablo Neira Ayuso <pablo@netfilter.org>2012-03-27 11:26:33 +0200
commit9d5d2b85c2f37b0f734d6a1a4b3ea2e36ead6519 (patch)
treef5c46ac8e3b68a65f8e754a665ca03354fe92687 /include
parentad96d6dd747cfc45116e4e600a3d22079e18a657 (diff)
nfacct: change prototype of nfacct_snprintf() to support output in XML
This patch adds supports for XML output for nfacct_snprintf(). This also bumps the library current version number and it adds a new version in the symbol map. I decided to do so because, although no official release has happened so far. Many distributors have already decided to provide packages for this. We don't provide the old symbol version for nfacct_snprintf, I think that's too much (given the lifetime of it). But we make sure that we break the binary gracefully in case of version mismatches (not silently, with unexpectable side effects). Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'include')
-rw-r--r--include/libnetfilter_acct/libnetfilter_acct.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/include/libnetfilter_acct/libnetfilter_acct.h b/include/libnetfilter_acct/libnetfilter_acct.h
index d877407..a57b571 100644
--- a/include/libnetfilter_acct/libnetfilter_acct.h
+++ b/include/libnetfilter_acct/libnetfilter_acct.h
@@ -32,6 +32,9 @@ int nfacct_nlmsg_parse_payload(const struct nlmsghdr *nlh, struct nfacct *nfacct
#define NFACCT_SNPRINTF_F_FULL (1 << 0)
-int nfacct_snprintf(char *buf, size_t size, struct nfacct *nfacct, unsigned int flags);
+#define NFACCT_SNPRINTF_T_PLAIN 0
+#define NFACCT_SNPRINTF_T_XML 1
+
+int nfacct_snprintf(char *buf, size_t size, struct nfacct *nfacct, uint16_t type, uint16_t flags);
#endif