|
Packit Service |
82fcde |
/* Copyright (C) 1997-2018 Free Software Foundation, Inc.
|
|
Packit Service |
82fcde |
This file is part of the GNU C Library.
|
|
Packit Service |
82fcde |
|
|
Packit Service |
82fcde |
The GNU C Library is free software; you can redistribute it and/or
|
|
Packit Service |
82fcde |
modify it under the terms of the GNU Lesser General Public
|
|
Packit Service |
82fcde |
License as published by the Free Software Foundation; either
|
|
Packit Service |
82fcde |
version 2.1 of the License, or (at your option) any later version.
|
|
Packit Service |
82fcde |
|
|
Packit Service |
82fcde |
The GNU C Library is distributed in the hope that it will be useful,
|
|
Packit Service |
82fcde |
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
Packit Service |
82fcde |
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
Packit Service |
82fcde |
Lesser General Public License for more details.
|
|
Packit Service |
82fcde |
|
|
Packit Service |
82fcde |
You should have received a copy of the GNU Lesser General Public
|
|
Packit Service |
82fcde |
License along with the GNU C Library; if not, see
|
|
Packit Service |
82fcde |
<http://www.gnu.org/licenses/>. */
|
|
Packit Service |
82fcde |
|
|
Packit Service |
82fcde |
#ifndef _UTMPX_H
|
|
Packit Service |
82fcde |
#define _UTMPX_H 1
|
|
Packit Service |
82fcde |
|
|
Packit Service |
82fcde |
#include <features.h>
|
|
Packit Service |
82fcde |
#include <sys/time.h>
|
|
Packit Service |
82fcde |
|
|
Packit Service |
82fcde |
/* Required according to Unix98. */
|
|
Packit Service |
82fcde |
#ifndef __pid_t_defined
|
|
Packit Service |
82fcde |
typedef __pid_t pid_t;
|
|
Packit Service |
82fcde |
# define __pid_t_defined
|
|
Packit Service |
82fcde |
#endif
|
|
Packit Service |
82fcde |
|
|
Packit Service |
82fcde |
/* Get system dependent values and data structures. */
|
|
Packit Service |
82fcde |
#include <bits/utmpx.h>
|
|
Packit Service |
82fcde |
|
|
Packit Service |
82fcde |
#ifdef __USE_GNU
|
|
Packit Service |
82fcde |
/* Compatibility names for the strings of the canonical file names. */
|
|
Packit Service |
82fcde |
# define UTMPX_FILE _PATH_UTMPX
|
|
Packit Service |
82fcde |
# define UTMPX_FILENAME _PATH_UTMPX
|
|
Packit Service |
82fcde |
# define WTMPX_FILE _PATH_WTMPX
|
|
Packit Service |
82fcde |
# define WTMPX_FILENAME _PATH_WTMPX
|
|
Packit Service |
82fcde |
#endif
|
|
Packit Service |
82fcde |
|
|
Packit Service |
82fcde |
/* For the getutmp{,x} functions we need the `struct utmp'. */
|
|
Packit Service |
82fcde |
#ifdef __USE_GNU
|
|
Packit Service |
82fcde |
struct utmp;
|
|
Packit Service |
82fcde |
#endif
|
|
Packit Service |
82fcde |
|
|
Packit Service |
82fcde |
|
|
Packit Service |
82fcde |
__BEGIN_DECLS
|
|
Packit Service |
82fcde |
|
|
Packit Service |
82fcde |
/* Open user accounting database.
|
|
Packit Service |
82fcde |
|
|
Packit Service |
82fcde |
This function is a possible cancellation point and therefore not
|
|
Packit Service |
82fcde |
marked with __THROW. */
|
|
Packit Service |
82fcde |
extern void setutxent (void);
|
|
Packit Service |
82fcde |
|
|
Packit Service |
82fcde |
/* Close user accounting database.
|
|
Packit Service |
82fcde |
|
|
Packit Service |
82fcde |
This function is a possible cancellation point and therefore not
|
|
Packit Service |
82fcde |
marked with __THROW. */
|
|
Packit Service |
82fcde |
extern void endutxent (void);
|
|
Packit Service |
82fcde |
|
|
Packit Service |
82fcde |
/* Get the next entry from the user accounting database.
|
|
Packit Service |
82fcde |
|
|
Packit Service |
82fcde |
This function is a possible cancellation point and therefore not
|
|
Packit Service |
82fcde |
marked with __THROW. */
|
|
Packit Service |
82fcde |
extern struct utmpx *getutxent (void);
|
|
Packit Service |
82fcde |
|
|
Packit Service |
82fcde |
/* Get the user accounting database entry corresponding to ID.
|
|
Packit Service |
82fcde |
|
|
Packit Service |
82fcde |
This function is a possible cancellation point and therefore not
|
|
Packit Service |
82fcde |
marked with __THROW. */
|
|
Packit Service |
82fcde |
extern struct utmpx *getutxid (const struct utmpx *__id);
|
|
Packit Service |
82fcde |
|
|
Packit Service |
82fcde |
/* Get the user accounting database entry corresponding to LINE.
|
|
Packit Service |
82fcde |
|
|
Packit Service |
82fcde |
This function is a possible cancellation point and therefore not
|
|
Packit Service |
82fcde |
marked with __THROW. */
|
|
Packit Service |
82fcde |
extern struct utmpx *getutxline (const struct utmpx *__line);
|
|
Packit Service |
82fcde |
|
|
Packit Service |
82fcde |
/* Write the entry UTMPX into the user accounting database.
|
|
Packit Service |
82fcde |
|
|
Packit Service |
82fcde |
This function is a possible cancellation point and therefore not
|
|
Packit Service |
82fcde |
marked with __THROW. */
|
|
Packit Service |
82fcde |
extern struct utmpx *pututxline (const struct utmpx *__utmpx);
|
|
Packit Service |
82fcde |
|
|
Packit Service |
82fcde |
|
|
Packit Service |
82fcde |
#ifdef __USE_GNU
|
|
Packit Service |
82fcde |
/* Change name of the utmpx file to be examined.
|
|
Packit Service |
82fcde |
|
|
Packit Service |
82fcde |
This function is not part of POSIX and therefore no official
|
|
Packit Service |
82fcde |
cancellation point. But due to similarity with an POSIX interface
|
|
Packit Service |
82fcde |
or due to the implementation it is a cancellation point and
|
|
Packit Service |
82fcde |
therefore not marked with __THROW. */
|
|
Packit Service |
82fcde |
extern int utmpxname (const char *__file);
|
|
Packit Service |
82fcde |
|
|
Packit Service |
82fcde |
/* Append entry UTMP to the wtmpx-like file WTMPX_FILE.
|
|
Packit Service |
82fcde |
|
|
Packit Service |
82fcde |
This function is not part of POSIX and therefore no official
|
|
Packit Service |
82fcde |
cancellation point. But due to similarity with an POSIX interface
|
|
Packit Service |
82fcde |
or due to the implementation it is a cancellation point and
|
|
Packit Service |
82fcde |
therefore not marked with __THROW. */
|
|
Packit Service |
82fcde |
extern void updwtmpx (const char *__wtmpx_file,
|
|
Packit Service |
82fcde |
const struct utmpx *__utmpx);
|
|
Packit Service |
82fcde |
|
|
Packit Service |
82fcde |
|
|
Packit Service |
82fcde |
/* Copy the information in UTMPX to UTMP.
|
|
Packit Service |
82fcde |
|
|
Packit Service |
82fcde |
This function is not part of POSIX and therefore no official
|
|
Packit Service |
82fcde |
cancellation point. But due to similarity with an POSIX interface
|
|
Packit Service |
82fcde |
or due to the implementation it is a cancellation point and
|
|
Packit Service |
82fcde |
therefore not marked with __THROW. */
|
|
Packit Service |
82fcde |
extern void getutmp (const struct utmpx *__utmpx,
|
|
Packit Service |
82fcde |
struct utmp *__utmp);
|
|
Packit Service |
82fcde |
|
|
Packit Service |
82fcde |
/* Copy the information in UTMP to UTMPX.
|
|
Packit Service |
82fcde |
|
|
Packit Service |
82fcde |
This function is not part of POSIX and therefore no official
|
|
Packit Service |
82fcde |
cancellation point. But due to similarity with an POSIX interface
|
|
Packit Service |
82fcde |
or due to the implementation it is a cancellation point and
|
|
Packit Service |
82fcde |
therefore not marked with __THROW. */
|
|
Packit Service |
82fcde |
extern void getutmpx (const struct utmp *__utmp, struct utmpx *__utmpx);
|
|
Packit Service |
82fcde |
#endif
|
|
Packit Service |
82fcde |
|
|
Packit Service |
82fcde |
__END_DECLS
|
|
Packit Service |
82fcde |
|
|
Packit Service |
82fcde |
#endif /* utmpx.h */
|