source: rtems/c/src/exec/posix/src/getgid.c @ aaf6063

4.104.114.84.9
Last change on this file since aaf6063 was aaf6063, checked in by Joel Sherrill <joel.sherrill@…>, on May 24, 2001 at 9:38:10 PM

2000-05-24 Fernando Ruiz Casas <fernando.ruiz@…>

  • src/getegid.c, src/geteuid.c, src/getgid.c, src/getlogin.c, src/getuid.c: Now save their values in private user environment.
  • Property mode set to 100644
File size: 634 bytes
Line 
1/*
2 *  $Id$
3 */
4
5#if HAVE_CONFIG_H
6#include "config.h"
7#endif
8
9#include <limits.h>
10#include <errno.h>
11#include <string.h>
12#include <sys/types.h>
13
14#include <rtems/system.h>
15#include <rtems/score/object.h>
16#include <rtems/seterr.h>
17
18#include <rtems/libio_.h>
19
20/*
21 * MACRO in libio_.h
22 *
23gid_t _POSIX_types_Gid = 0;
24*/
25
26/*PAGE
27 *
28 *  4.2.1 Get Real User, Effective User, Ral Group, and Effective Group IDs,
29 *        P1003.1b-1993, p. 84
30 */
31
32gid_t getgid( void )
33{
34  return _POSIX_types_Gid;
35}
36
37/*PAGE
38 *
39 *  4.2.2 Set User and Group IDs, P1003.1b-1993, p. 84
40 */
41
42int setgid(
43  gid_t  gid
44)
45{
46  _POSIX_types_Gid = gid;
47  return 0;
48}
Note: See TracBrowser for help on using the repository browser.