| version 1.10, 1995/08/24 05:26:35 |
version 1.10.4.2, 1996/09/19 20:02:39 |
| Line 44 static char rcsid[] = "$NetBSD$"; |
|
| Line 44 static char rcsid[] = "$NetBSD$"; |
|
| #endif |
#endif |
| #endif /* LIBC_SCCS and not lint */ |
#endif /* LIBC_SCCS and not lint */ |
| |
|
| |
#include "namespace.h" |
| #include <sys/types.h> |
#include <sys/types.h> |
| |
|
| #include <ctype.h> |
#include <ctype.h> |
| Line 56 static char rcsid[] = "$NetBSD$"; |
|
| Line 57 static char rcsid[] = "$NetBSD$"; |
|
| #include <string.h> |
#include <string.h> |
| #include <unistd.h> |
#include <unistd.h> |
| |
|
| |
#ifdef __weak_alias |
| |
__weak_alias(cgetcap,_cgetcap); |
| |
__weak_alias(cgetclose,_cgetclose); |
| |
__weak_alias(cgetent,_cgetent); |
| |
__weak_alias(cgetfirst,_cgetfirst); |
| |
__weak_alias(cgetmatch,_cgetmatch); |
| |
__weak_alias(cgetnext,_cgetnext); |
| |
__weak_alias(cgetnum,_cgetnum); |
| |
__weak_alias(cgetset,_cgetset); |
| |
__weak_alias(cgetstr,_cgetstr); |
| |
__weak_alias(cgetustr,_cgetustr); |
| |
#endif |
| |
|
| #define BFRAG 1024 |
#define BFRAG 1024 |
| #define BSIZE 1024 |
#define BSIZE 1024 |
| #define ESC ('[' & 037) /* ASCII ESC */ |
#define ESC ('[' & 037) /* ASCII ESC */ |
| Line 248 getent(cap, len, db_array, fd, name, dep |
|
| Line 262 getent(cap, len, db_array, fd, name, dep |
|
| */ |
*/ |
| |
|
| if (fd >= 0) { |
if (fd >= 0) { |
| (void)lseek(fd, (off_t)0, L_SET); |
(void)lseek(fd, (off_t)0, SEEK_SET); |
| myfd = 0; |
myfd = 0; |
| } else { |
} else { |
| (void)snprintf(pbuf, sizeof(pbuf), "%s.db", *db_p); |
(void)snprintf(pbuf, sizeof(pbuf), "%s.db", *db_p); |