version 1.13, 2016/01/19 15:59:12 |
version 1.14, 2016/10/10 13:54:47 |
|
|
RB_ENTRY(args_entry) entry; |
RB_ENTRY(args_entry) entry; |
}; |
}; |
|
|
struct args_entry *args_find(struct args *, u_char); |
static struct args_entry *args_find(struct args *, u_char); |
|
|
RB_GENERATE(args_tree, args_entry, entry, args_cmp); |
static int args_cmp(struct args_entry *, struct args_entry *); |
|
RB_GENERATE_STATIC(args_tree, args_entry, entry, args_cmp); |
|
|
/* Arguments tree comparison function. */ |
/* Arguments tree comparison function. */ |
int |
static int |
args_cmp(struct args_entry *a1, struct args_entry *a2) |
args_cmp(struct args_entry *a1, struct args_entry *a2) |
{ |
{ |
return (a1->flag - a2->flag); |
return (a1->flag - a2->flag); |
|
|
} |
} |
|
|
/* Find a flag in the arguments tree. */ |
/* Find a flag in the arguments tree. */ |
struct args_entry * |
static struct args_entry * |
args_find(struct args *args, u_char ch) |
args_find(struct args *args, u_char ch) |
{ |
{ |
struct args_entry entry; |
struct args_entry entry; |