14 * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15 * If applicable, add the following below this CDDL HEADER, with the
16 * fields enclosed by brackets "[]" replaced with your own identifying
17 * information: Portions Copyright [yyyy] [name of copyright owner]
18 *
19 * CDDL HEADER END
20 */
21 /*
22 * Copyright 2008 Sun Microsystems, Inc. All rights reserved.
23 * Use is subject to license terms.
24 */
25
26 /* Copyright (c) 1983, 1984, 1985, 1986, 1987, 1988, 1989 AT&T */
27 /* All Rights Reserved */
28
29 /*
30 * Portions of this source code were derived from Berkeley 4.3 BSD
31 * under license from the Regents of the University of California.
32 */
33
34 #pragma ident "%Z%%M% %I% %E% SMI"
35
36 /*
37 * chown [-fhR] uid[:gid] file ...
38 * chown -R [-f] [-H|-L|-P] uid[:gid] file ...
39 * chown -s [-fhR] ownersid[:groupsid] file ...
40 * chown -s -R [-f] [-H|-L|-P] ownersid[:groupsid] file ...
41 */
42
43 #include <stdio.h>
44 #include <stdlib.h>
45 #include <ctype.h>
46 #include <sys/types.h>
47 #include <dirent.h>
48 #include <string.h>
49 #include <sys/stat.h>
50 #include <sys/avl.h>
51 #include <pwd.h>
52 #include <grp.h>
53 #include <unistd.h>
54 #include <locale.h>
|
14 * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15 * If applicable, add the following below this CDDL HEADER, with the
16 * fields enclosed by brackets "[]" replaced with your own identifying
17 * information: Portions Copyright [yyyy] [name of copyright owner]
18 *
19 * CDDL HEADER END
20 */
21 /*
22 * Copyright 2008 Sun Microsystems, Inc. All rights reserved.
23 * Use is subject to license terms.
24 */
25
26 /* Copyright (c) 1983, 1984, 1985, 1986, 1987, 1988, 1989 AT&T */
27 /* All Rights Reserved */
28
29 /*
30 * Portions of this source code were derived from Berkeley 4.3 BSD
31 * under license from the Regents of the University of California.
32 */
33
34 /*
35 * Copyright (c) 2018, Joyent, Inc.
36 */
37
38 /*
39 * chown [-fhR] uid[:gid] file ...
40 * chown -R [-f] [-H|-L|-P] uid[:gid] file ...
41 * chown -s [-fhR] ownersid[:groupsid] file ...
42 * chown -s -R [-f] [-H|-L|-P] ownersid[:groupsid] file ...
43 */
44
45 #include <stdio.h>
46 #include <stdlib.h>
47 #include <ctype.h>
48 #include <sys/types.h>
49 #include <dirent.h>
50 #include <string.h>
51 #include <sys/stat.h>
52 #include <sys/avl.h>
53 #include <pwd.h>
54 #include <grp.h>
55 #include <unistd.h>
56 #include <locale.h>
|