34471fa0787dd88783667f9e1be713f840973996
[debian/tar] / gnu / selinux-at.c
1 /* -*- buffer-read-only: t -*- vi: set ro: */
2 /* DO NOT EDIT! GENERATED AUTOMATICALLY! */
3 /* openat-style fd-relative functions for SE Linux
4    Copyright (C) 2007, 2009-2013 Free Software Foundation, Inc.
5
6    This program is free software: you can redistribute it and/or modify
7    it under the terms of the GNU General Public License as published by
8    the Free Software Foundation, either version 3 of the License, or
9    (at your option) any later version.
10
11    This program is distributed in the hope that it will be useful,
12    but WITHOUT ANY WARRANTY; without even the implied warranty of
13    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14    GNU General Public License for more details.
15
16    You should have received a copy of the GNU General Public License
17    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
18
19 /* written by Jim Meyering */
20
21 #include <config.h>
22
23 #include "selinux-at.h"
24 #include "openat.h"
25
26 #include <stdlib.h>
27 #include <unistd.h>
28 #include <errno.h>
29 #include <fcntl.h>
30
31 #include "dirname.h" /* solely for definition of IS_ABSOLUTE_FILE_NAME */
32 #include "save-cwd.h"
33
34 #include "openat-priv.h"
35
36 #define AT_FUNC_NAME getfileconat
37 #define AT_FUNC_F1 getfilecon
38 #define AT_FUNC_POST_FILE_PARAM_DECLS , security_context_t *con
39 #define AT_FUNC_POST_FILE_ARGS        , con
40 #include "at-func.c"
41 #undef AT_FUNC_NAME
42 #undef AT_FUNC_F1
43 #undef AT_FUNC_POST_FILE_PARAM_DECLS
44 #undef AT_FUNC_POST_FILE_ARGS
45
46 #define AT_FUNC_NAME lgetfileconat
47 #define AT_FUNC_F1 lgetfilecon
48 #define AT_FUNC_POST_FILE_PARAM_DECLS , security_context_t *con
49 #define AT_FUNC_POST_FILE_ARGS        , con
50 #include "at-func.c"
51 #undef AT_FUNC_NAME
52 #undef AT_FUNC_F1
53 #undef AT_FUNC_POST_FILE_PARAM_DECLS
54 #undef AT_FUNC_POST_FILE_ARGS
55
56 #define AT_FUNC_NAME setfileconat
57 #define AT_FUNC_F1 setfilecon
58 #define AT_FUNC_POST_FILE_PARAM_DECLS , security_context_t con
59 #define AT_FUNC_POST_FILE_ARGS        , con
60 #include "at-func.c"
61 #undef AT_FUNC_NAME
62 #undef AT_FUNC_F1
63 #undef AT_FUNC_POST_FILE_PARAM_DECLS
64 #undef AT_FUNC_POST_FILE_ARGS
65
66 #define AT_FUNC_NAME lsetfileconat
67 #define AT_FUNC_F1 lsetfilecon
68 #define AT_FUNC_POST_FILE_PARAM_DECLS , security_context_t con
69 #define AT_FUNC_POST_FILE_ARGS        , con
70 #include "at-func.c"
71 #undef AT_FUNC_NAME
72 #undef AT_FUNC_F1
73 #undef AT_FUNC_POST_FILE_PARAM_DECLS
74 #undef AT_FUNC_POST_FILE_ARGS