Changeset View
Changeset View
Standalone View
Standalone View
usr.sbin/inetd/inetd.h
Show All 32 Lines | |||||
#include <sys/time.h> | #include <sys/time.h> | ||||
#include <sys/socket.h> | #include <sys/socket.h> | ||||
#include <sys/un.h> | #include <sys/un.h> | ||||
#include <sys/queue.h> | #include <sys/queue.h> | ||||
#include <netinet/in.h> | #include <netinet/in.h> | ||||
#include <stdbool.h> | |||||
#include <stdio.h> | #include <stdio.h> | ||||
#define BUFSIZE 8192 | #define BUFSIZE 8192 | ||||
#define LINESIZ 72 | #define LINESIZ 72 | ||||
#define NORM_TYPE 0 | #define NORM_TYPE 0 | ||||
#define MUX_TYPE 1 | #define MUX_TYPE 1 | ||||
#define MUXPLUS_TYPE 2 | #define MUXPLUS_TYPE 2 | ||||
▲ Show 20 Lines • Show All 99 Lines • ▼ Show 20 Lines | struct biltin { | ||||
int bi_socktype; /* type of socket supported */ | int bi_socktype; /* type of socket supported */ | ||||
short bi_flags; /* BIF_* flags below */ | short bi_flags; /* BIF_* flags below */ | ||||
int bi_maxchild; /* max number of children, -1=default */ | int bi_maxchild; /* max number of children, -1=default */ | ||||
bi_fn_t *bi_fn; /* function which performs it */ | bi_fn_t *bi_fn; /* function which performs it */ | ||||
}; | }; | ||||
extern struct biltin biltins[]; | extern struct biltin biltins[]; | ||||
#define BIF_FORK 0x0001 /* should fork before call */ | #define BIF_FORK 0x0001 /* should fork before call */ | ||||
#define BIF_CAPENTER 0x0002 /* enter capability mode upon fork */ | |||||
#define SERVTAB_FORK(sep) \ | #define SERVTAB_FORK(sep) \ | ||||
((sep)->se_bi == NULL || ((sep)->se_bi->bi_flags & BIF_FORK) != 0) | ((sep)->se_bi == NULL || \ | ||||
((sep)->se_bi->bi_flags & (BIF_FORK | BIF_CAPENTER)) != 0) | |||||
#define SERVTAB_CAPENTER(sep) \ | |||||
((sep)->se_bi != NULL && ((sep)->se_bi->bi_flags & BIF_CAPENTER) != 0) |