Bundle libseccomp 2.3.1
[linux-seccomp.git] / libseccomp / doc / man / man3 / seccomp_release.3
CommitLineData
8befd5cc
MG
1.TH "seccomp_release" 3 "25 July 2012" "paul@paul-moore.com" "libseccomp Documentation"
2.\" //////////////////////////////////////////////////////////////////////////
3.SH NAME
4.\" //////////////////////////////////////////////////////////////////////////
5seccomp_release \- Release the seccomp filter state
6.\" //////////////////////////////////////////////////////////////////////////
7.SH SYNOPSIS
8.\" //////////////////////////////////////////////////////////////////////////
9.nf
10.B #include <seccomp.h>
11.sp
12.B typedef void * scmp_filter_ctx;
13.sp
14.BI "void seccomp_release(scmp_filter_ctx " ctx ");"
15.sp
16Link with \fI\-lseccomp\fP.
17.fi
18.\" //////////////////////////////////////////////////////////////////////////
19.SH DESCRIPTION
20.\" //////////////////////////////////////////////////////////////////////////
21.P
22Releases the seccomp filter in
23.I ctx
24which was first initialized by
25.BR seccomp_init (3)
26or
27.BR seccomp_reset (3)
28and frees any memory associated with the given seccomp filter context.
29Any seccomp filters loaded into the kernel are not affected.
30.\" //////////////////////////////////////////////////////////////////////////
31.SH RETURN VALUE
32.\" //////////////////////////////////////////////////////////////////////////
33Does not return a value.
34.\" //////////////////////////////////////////////////////////////////////////
35.SH EXAMPLES
36.\" //////////////////////////////////////////////////////////////////////////
37.nf
38#include <seccomp.h>
39
40int main(int argc, char *argv[])
41{
42 int rc;
43 scmp_filter_ctx ctx;
44
45 ctx = seccomp_init(SCMP_ACT_KILL);
46 if (ctx == NULL)
47 return \-1;
48
49 /* ... */
50
51 seccomp_release(ctx);
52 return 0;
53}
54.fi
55.\" //////////////////////////////////////////////////////////////////////////
56.SH NOTES
57.\" //////////////////////////////////////////////////////////////////////////
58.P
59While the seccomp filter can be generated independent of the kernel, kernel
60support is required to load and enforce the seccomp filter generated by
61libseccomp.
62.P
63The libseccomp project site, with more information and the source code
64repository, can be found at https://github.com/seccomp/libseccomp. This tool,
65as well as the libseccomp library, is currently under development, please
66report any bugs at the project site or directly to the author.
67.\" //////////////////////////////////////////////////////////////////////////
68.SH AUTHOR
69.\" //////////////////////////////////////////////////////////////////////////
70Paul Moore <paul@paul-moore.com>
71.\" //////////////////////////////////////////////////////////////////////////
72.SH SEE ALSO
73.\" //////////////////////////////////////////////////////////////////////////
74.BR seccomp_init (3),
75.BR seccomp_reset (3)
76
77
This page took 0.013597 seconds and 4 git commands to generate.