summaryrefslogtreecommitdiffstats
path: root/lib/session.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/session.c')
-rw-r--r--lib/session.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/lib/session.c b/lib/session.c
index 6700ea1..3803bfa 100644
--- a/lib/session.c
+++ b/lib/session.c
@@ -1941,6 +1941,19 @@ cleanup:
}
/**
+ * ipset_session_outfn - set session output printing function
+ *
+ * Set the session printing function.
+ *
+ */
+int
+ipset_session_outfn(struct ipset_session *session, ipset_outfn outfn)
+{
+ session->outfn = outfn ? outfn : printf;
+ return 0;
+}
+
+/**
* ipset_session_init - initialize an ipset session
*
* Initialize an ipset session by allocating a session structure