os/ossrv/genericopenlibs/openenvcore/include/utmp.h
changeset 0 bde4ae8d615e
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/os/ossrv/genericopenlibs/openenvcore/include/utmp.h	Fri Jun 15 03:10:57 2012 +0200
     1.3 @@ -0,0 +1,67 @@
     1.4 +// utmp.h
     1.5 +
     1.6 +/*
     1.7 + * Copyright (c) 1988, 1993
     1.8 + *	The Regents of the University of California.  All rights reserved.
     1.9 + * (c) UNIX System Laboratories, Inc.
    1.10 + * All or some portions of this file are derived from material licensed
    1.11 + * to the University of California by American Telephone and Telegraph
    1.12 + * Co. or Unix System Laboratories, Inc. and are reproduced herein with
    1.13 + * the permission of UNIX System Laboratories, Inc.
    1.14 + *
    1.15 + * Redistribution and use in source and binary forms, with or without
    1.16 + * modification, are permitted provided that the following conditions
    1.17 + * are met:
    1.18 + * 1. Redistributions of source code must retain the above copyright
    1.19 + *    notice, this list of conditions and the following disclaimer.
    1.20 + * 2. Redistributions in binary form must reproduce the above copyright
    1.21 + *    notice, this list of conditions and the following disclaimer in the
    1.22 + *    documentation and/or other materials provided with the distribution.
    1.23 + * 4. Neither the name of the University nor the names of its contributors
    1.24 + *    may be used to endorse or promote products derived from this software
    1.25 + *    without specific prior written permission.
    1.26 + *
    1.27 + * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
    1.28 + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
    1.29 + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
    1.30 + * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
    1.31 + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
    1.32 + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
    1.33 + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
    1.34 + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
    1.35 + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
    1.36 + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
    1.37 + * SUCH DAMAGE.
    1.38 + *
    1.39 + * Portions Copyright (c) 2006 Nokia Corporation and/or its subsidiary(-ies). All rights reserved.
    1.40 + *	@(#)utmp.h	8.2 (Berkeley) 1/21/94
    1.41 + * $FreeBSD: src/include/utmp.h,v 1.10 2001/10/27 20:40:54 peter Exp $
    1.42 + */
    1.43 +
    1.44 +#ifndef	_UTMP_H_ 
    1.45 +#define	_UTMP_H_
    1.46 +
    1.47 +#include <sys/types.h>
    1.48 +
    1.49 +#define	_PATH_UTMP	"/var/run/utmp"
    1.50 +#define	_PATH_WTMP	"/var/log/wtmp"
    1.51 +#define	_PATH_LASTLOG	"/var/log/lastlog"
    1.52 +
    1.53 +#define	UT_NAMESIZE	16	/* see MAXLOGNAME in <sys/param.h> */
    1.54 +#define	UT_LINESIZE	8
    1.55 +#define	UT_HOSTSIZE	16
    1.56 +
    1.57 +struct lastlog {
    1.58 +	int32_t	ll_time;
    1.59 +	char	ll_line[UT_LINESIZE];
    1.60 +	char	ll_host[UT_HOSTSIZE];
    1.61 +};
    1.62 +
    1.63 +struct utmp {
    1.64 +	char	ut_line[UT_LINESIZE];
    1.65 +	char	ut_name[UT_NAMESIZE];
    1.66 +	char	ut_host[UT_HOSTSIZE];
    1.67 +	int32_t	ut_time;
    1.68 +};
    1.69 +
    1.70 +#endif /* !_UTMP_H_ */