add gettytab
This commit is contained in:
parent
b11674e1a4
commit
1d50c3e36a
@ -1,4 +1,4 @@
|
||||
.\" $NetBSD: getent.1,v 1.14 2008/02/01 22:39:20 christos Exp $
|
||||
.\" $NetBSD: getent.1,v 1.15 2008/02/04 15:30:44 christos Exp $
|
||||
.\"
|
||||
.\" Copyright (c) 2004 The NetBSD Foundation, Inc.
|
||||
.\" All rights reserved.
|
||||
@ -34,7 +34,7 @@
|
||||
.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
|
||||
.\" POSSIBILITY OF SUCH DAMAGE.
|
||||
.\"
|
||||
.Dd February 1, 2008
|
||||
.Dd February 4, 2008
|
||||
.Dt GETENT 1
|
||||
.Os
|
||||
.Sh NAME
|
||||
@ -60,10 +60,11 @@ file format for that database.
|
||||
.Pp
|
||||
.Ar database
|
||||
may be one of:
|
||||
.Bl -column "netgroup" -offset indent -compact
|
||||
.Bl -column "protocols" -offset indent -compact
|
||||
.Sy Database Ta Sy Display format
|
||||
.It disktab Ta entry
|
||||
.It ethers Ta address name
|
||||
.It gettytab Ta entry
|
||||
.It group Ta group:passwd:gid:[member[,member]...]
|
||||
.It hosts Ta address name [alias ...]
|
||||
.It networks Ta name network [alias ...]
|
||||
@ -124,16 +125,20 @@ or 3 if there is no support for enumeration on
|
||||
.Ar database .
|
||||
.Sh SEE ALSO
|
||||
.Xr cgetcap 3 ,
|
||||
.Xr disktab 5 ,
|
||||
.Xr ethers 5 ,
|
||||
.Xr gettytab 5 ,
|
||||
.Xr group 5 ,
|
||||
.Xr hosts 5 ,
|
||||
.Xr networks 5 ,
|
||||
.Xr nsswitch.conf 5 ,
|
||||
.Xr passwd 5 ,
|
||||
.Xr protocols 5 ,
|
||||
.Xr printcap 5 ,
|
||||
.Xr rpc 5 ,
|
||||
.Xr services 5 ,
|
||||
.Xr shells 5
|
||||
.Xr shells 5 ,
|
||||
.Xr termcap 5
|
||||
.Sh HISTORY
|
||||
A
|
||||
.Nm
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: getent.c,v 1.11 2008/02/02 20:57:20 christos Exp $ */
|
||||
/* $NetBSD: getent.c,v 1.12 2008/02/04 15:30:45 christos Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 2004-2006 The NetBSD Foundation, Inc.
|
||||
@ -38,7 +38,7 @@
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
#ifndef lint
|
||||
__RCSID("$NetBSD: getent.c,v 1.11 2008/02/02 20:57:20 christos Exp $");
|
||||
__RCSID("$NetBSD: getent.c,v 1.12 2008/02/04 15:30:45 christos Exp $");
|
||||
#endif /* not lint */
|
||||
|
||||
#include <sys/socket.h>
|
||||
@ -73,6 +73,7 @@ __RCSID("$NetBSD: getent.c,v 1.11 2008/02/02 20:57:20 christos Exp $");
|
||||
static int usage(void) __attribute__((__noreturn__));
|
||||
static int parsenum(const char *, unsigned long *);
|
||||
static int disktab(int, char *[]);
|
||||
static int gettytab(int, char *[]);
|
||||
static int ethers(int, char *[]);
|
||||
static int group(int, char *[]);
|
||||
static int hosts(int, char *[]);
|
||||
@ -98,6 +99,7 @@ static struct getentdb {
|
||||
} databases[] = {
|
||||
{ "disktab", disktab, },
|
||||
{ "ethers", ethers, },
|
||||
{ "gettytab", gettytab, },
|
||||
{ "group", group, },
|
||||
{ "hosts", hosts, },
|
||||
{ "networks", networks, },
|
||||
@ -611,6 +613,16 @@ handlecap(const char *db, int argc, char *argv[])
|
||||
return rv;
|
||||
}
|
||||
|
||||
/*
|
||||
* gettytab
|
||||
*/
|
||||
|
||||
static int
|
||||
gettytab(int argc, char *argv[])
|
||||
{
|
||||
return handlecap(_PATH_GETTYTAB, argc, argv);
|
||||
}
|
||||
|
||||
/*
|
||||
* printcap
|
||||
*/
|
||||
|
Loading…
Reference in New Issue
Block a user