blob: 00923a03cb5472e16afb2056db93151543e0c23d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
/*
* $Id: iplist.h,v 1.1 1997/12/15 22:44:54 brian Exp $
*/
struct iplist {
struct iplist_cur {
struct in_addr ip;
int pos;
char *srcptr;
int srcitem;
u_long lstart, nItems;
} cur;
int nItems;
char src[LINE_LEN];
};
extern int iplist_setsrc(struct iplist *, const char *);
extern void iplist_reset(struct iplist *);
extern struct in_addr iplist_setcurpos(struct iplist *, int);
extern struct in_addr iplist_setrandpos(struct iplist *);
extern int iplist_ip2pos(struct iplist *, struct in_addr);
extern struct in_addr iplist_next(struct iplist *);
#define iplist_isvalid(x) ((x)->src[0] != '\0')
|