aboutsummaryrefslogtreecommitdiffstats
path: root/ports/linux/guts/getresuid.c
blob: 59816d4835a8ef01bb6e8ea89a3130aa373c2459 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
/* 
 * Copyright (c) 2008-2010 Wind River Systems; see
 * guts/COPYRIGHT for information.
 *
 * SPDX-License-Identifier: LGPL-2.1-only
 *
 * static int
 * wrap_getresuid(uid_t *ruid, uid_t *euid, uid_t *suid) {
 *	int rc = -1;
 */
	if (ruid)
		*ruid = pseudo_ruid;
	if (euid)
		*euid = pseudo_euid;
	if (suid)
		*suid = pseudo_suid;
	if (ruid && euid && suid) {
		rc = 0;
	} else {
		rc = -1;
		errno = EFAULT;
	}
/*	return rc;
 * }
 */