/***********************************************************************
* *
* This software is part of the ast package *
* Copyright (c) 1982-2012 AT&T Intellectual Property *
* and is licensed under the *
* Eclipse Public License, Version 1.0 *
* by AT&T Intellectual Property *
* *
* A copy of the License is available at *
* (with md5 checksum b35adb5213ca9657e911e9befb180842) *
* *
* Information and Software Systems Research *
* AT&T Research *
* Florham Park NJ *
* *
* David Korn <dgk@research.att.com> *
* *
***********************************************************************/
#pragma prototyped
#ifndef _ULIMIT_H
/*
* This is for the ulimit built-in command
*/
#if defined(_sys_resource) && defined(_lib_getrlimit)
# include <sys/resource.h>
# if !defined(RLIMIT_FSIZE) && defined(_sys_vlimit)
# ifdef LIM_MAXRSS
# endif /* LIM_MAXRSS */
# endif
#else
# ifdef _sys_vlimit
# ifdef LIM_MAXRSS
# endif /* LIM_MAXRSS */
# else
# ifdef _lib_ulimit
# endif /* _lib_ulimit */
# endif /* _lib_vlimit */
#endif
#ifdef RLIM_INFINITY
#else
# ifndef INFINITY
# endif /* INFINITY */
#endif /* RLIM_INFINITY */
# ifndef RLIMIT_VMEM
# ifdef RLIMIT_AS
# endif
# endif /* !RLIMIT_VMEM */
#else
# define _no_ulimit
#endif
#ifndef _typ_rlim_t
typedef long rlim_t;
#endif
#if !defined(RLIMIT_NOFILE) && defined(RLIMIT_OFILE)
#endif
#ifndef RLIMIT_UNKNOWN
#endif
#ifndef RLIMIT_AS
#endif
#ifndef RLIMIT_CORE
#endif
#ifndef RLIMIT_CPU
#endif
#ifndef RLIMIT_DATA
#endif
#ifndef RLIMIT_FSIZE
#endif
#ifndef RLIMIT_LOCKS
#endif
#ifndef RLIMIT_MEMLOCK
#endif
#ifndef RLIMIT_MSGQUEUE
#endif
#ifndef RLIMIT_NOFILE
#endif
#ifndef RLIMIT_NICE
#endif
#ifndef RLIMIT_NPROC
#endif
#ifndef RLIMIT_PIPE
#endif
#ifndef RLIMIT_PTHREAD
#endif
#ifndef RLIMIT_RSS
#endif
#ifndef RLIMIT_RTPRIO
#endif
#ifndef RLIMIT_SBSIZE
#endif
#ifndef RLIMIT_SIGPENDING
#endif
#ifndef RLIMIT_STACK
#endif
#ifndef RLIMIT_SWAP
#endif
#ifndef RLIMIT_VMEM
#endif
#define LIM_COUNT 0
typedef struct Limit_s
{
const char* description;
int index;
const char* conf;
unsigned char option;
unsigned char type;
} Limit_t;
extern const Limit_t shtab_limits[];
extern const int shtab_units[];
extern const char e_unlimited[];
extern const char* e_units[];
#endif /* _ULIMIT_H */