Print this page
remove support for non-ANSI compilation
Split |
Close |
Expand all |
Collapse all |
--- old/usr/src/head/ucred.h
+++ new/usr/src/head/ucred.h
1 1 /*
2 2 * CDDL HEADER START
3 3 *
4 4 * The contents of this file are subject to the terms of the
5 5 * Common Development and Distribution License (the "License").
6 6 * You may not use this file except in compliance with the License.
7 7 *
8 8 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9 9 * or http://www.opensolaris.org/os/licensing.
10 10 * See the License for the specific language governing permissions
11 11 * and limitations under the License.
↓ open down ↓ |
11 lines elided |
↑ open up ↑ |
12 12 *
13 13 * When distributing Covered Code, include this CDDL HEADER in each
14 14 * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15 15 * If applicable, add the following below this CDDL HEADER, with the
16 16 * fields enclosed by brackets "[]" replaced with your own identifying
17 17 * information: Portions Copyright [yyyy] [name of copyright owner]
18 18 *
19 19 * CDDL HEADER END
20 20 */
21 21 /*
22 + * Copyright 2014 Garrett D'Amore <garrett@damore.org>
23 + *
22 24 * Copyright 2006 Sun Microsystems, Inc. All rights reserved.
23 25 * Use is subject to license terms.
24 26 */
25 27
26 28 #ifndef _UCRED_H_
27 29 #define _UCRED_H_
28 30
29 -#pragma ident "%Z%%M% %I% %E% SMI"
30 -
31 31 #include <sys/types.h>
32 32 #include <sys/priv.h>
33 33 #include <sys/tsol/label.h>
34 34
35 35 #ifdef __cplusplus
36 36 extern "C" {
37 37 #endif
38 38
39 39 typedef struct ucred_s ucred_t;
40 40
41 41 /*
42 42 * library functions prototype.
43 43 */
44 -#if defined(__STDC__)
45 44
46 45 extern ucred_t *ucred_get(pid_t pid);
47 46
48 47 extern void ucred_free(ucred_t *);
49 48
50 49 extern uid_t ucred_geteuid(const ucred_t *);
51 50 extern uid_t ucred_getruid(const ucred_t *);
52 51 extern uid_t ucred_getsuid(const ucred_t *);
53 52 extern gid_t ucred_getegid(const ucred_t *);
54 53 extern gid_t ucred_getrgid(const ucred_t *);
55 54 extern gid_t ucred_getsgid(const ucred_t *);
56 55 extern int ucred_getgroups(const ucred_t *, const gid_t **);
57 56
58 57 extern const priv_set_t *ucred_getprivset(const ucred_t *, priv_ptype_t);
59 58 extern uint_t ucred_getpflags(const ucred_t *, uint_t);
60 59
61 60 extern pid_t ucred_getpid(const ucred_t *); /* for door_cred compatibility */
62 61
↓ open down ↓ |
8 lines elided |
↑ open up ↑ |
63 62 extern size_t ucred_size(void);
64 63
65 64 extern int getpeerucred(int, ucred_t **);
66 65
67 66 extern zoneid_t ucred_getzoneid(const ucred_t *);
68 67
69 68 extern bslabel_t *ucred_getlabel(const ucred_t *);
70 69
71 70 extern projid_t ucred_getprojid(const ucred_t *);
72 71
73 -#else /* Non ANSI */
74 -
75 -extern ucred_t *ucred_get(/* pid_t pid */);
76 -
77 -extern void ucred_free(/* ucred_t * */);
78 -
79 -extern uid_t ucred_geteuid(/* ucred_t * */);
80 -extern uid_t ucred_getruid(/* ucred_t * */);
81 -extern uid_t ucred_getsuid(/* ucred_t * */);
82 -extern gid_t ucred_getegid(/* ucred_t * */);
83 -extern gid_t ucred_getrgid(/* ucred_t * */);
84 -extern gid_t ucred_getsgid(/* ucred_t * */);
85 -extern int ucred_getgroups(/* ucred_t *, gid_t ** */);
86 -
87 -extern priv_set_t *ucred_getprivset(/* ucred_t *, priv_ptype_t */);
88 -extern uint_t ucred_getpflags(/* ucred_t *, uint_t */);
89 -
90 -extern pid_t ucred_getpid(/* ucred_t * */);
91 -
92 -extern size_t ucred_size(/* void */);
93 -
94 -extern int getpeerucred(/* int, ucred_t ** */);
95 -
96 -extern zoneid_t ucred_getzoneid(/* ucred_t * */);
97 -
98 -extern bslabel_t *ucred_getlabel(/* const ucred_t * */);
99 -
100 -extern projid_t ucred_getprojid(/* ucred_t * */);
101 -
102 -#endif /* __STDC__ */
103 -
104 72 #ifdef __cplusplus
105 73 }
106 74 #endif
107 75
108 76 #endif /* _UCRED_H_ */
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX