mirror of
https://github.com/tmux/tmux.git
synced 2025-04-25 06:08:53 +00:00
Some more static.
This commit is contained in:
parent
b8f2dd8237
commit
7d4b416fe6
@ -35,12 +35,13 @@ struct args_entry {
|
|||||||
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);
|
||||||
@ -71,7 +72,7 @@ args_create(int argc, ...)
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* 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;
|
||||||
|
22
paste.c
22
paste.c
@ -43,27 +43,27 @@ struct paste_buffer {
|
|||||||
RB_ENTRY(paste_buffer) time_entry;
|
RB_ENTRY(paste_buffer) time_entry;
|
||||||
};
|
};
|
||||||
|
|
||||||
u_int paste_next_index;
|
static u_int paste_next_index;
|
||||||
u_int paste_next_order;
|
static u_int paste_next_order;
|
||||||
u_int paste_num_automatic;
|
static u_int paste_num_automatic;
|
||||||
RB_HEAD(paste_name_tree, paste_buffer) paste_by_name;
|
RB_HEAD(paste_name_tree, paste_buffer) paste_by_name;
|
||||||
RB_HEAD(paste_time_tree, paste_buffer) paste_by_time;
|
RB_HEAD(paste_time_tree, paste_buffer) paste_by_time;
|
||||||
|
|
||||||
int paste_cmp_names(const struct paste_buffer *, const struct paste_buffer *);
|
static int paste_cmp_names(const struct paste_buffer *,
|
||||||
RB_PROTOTYPE(paste_name_tree, paste_buffer, name_entry, paste_cmp_names);
|
const struct paste_buffer *);
|
||||||
RB_GENERATE(paste_name_tree, paste_buffer, name_entry, paste_cmp_names);
|
RB_GENERATE_STATIC(paste_name_tree, paste_buffer, name_entry, paste_cmp_names);
|
||||||
|
|
||||||
int paste_cmp_times(const struct paste_buffer *, const struct paste_buffer *);
|
static int paste_cmp_times(const struct paste_buffer *,
|
||||||
RB_PROTOTYPE(paste_time_tree, paste_buffer, time_entry, paste_cmp_times);
|
const struct paste_buffer *);
|
||||||
RB_GENERATE(paste_time_tree, paste_buffer, time_entry, paste_cmp_times);
|
RB_GENERATE_STATIC(paste_time_tree, paste_buffer, time_entry, paste_cmp_times);
|
||||||
|
|
||||||
int
|
static int
|
||||||
paste_cmp_names(const struct paste_buffer *a, const struct paste_buffer *b)
|
paste_cmp_names(const struct paste_buffer *a, const struct paste_buffer *b)
|
||||||
{
|
{
|
||||||
return (strcmp(a->name, b->name));
|
return (strcmp(a->name, b->name));
|
||||||
}
|
}
|
||||||
|
|
||||||
int
|
static int
|
||||||
paste_cmp_times(const struct paste_buffer *a, const struct paste_buffer *b)
|
paste_cmp_times(const struct paste_buffer *a, const struct paste_buffer *b)
|
||||||
{
|
{
|
||||||
if (a->order > b->order)
|
if (a->order > b->order)
|
||||||
|
2
tmux.h
2
tmux.h
@ -1798,8 +1798,6 @@ void tty_keys_free(struct tty *);
|
|||||||
key_code tty_keys_next(struct tty *);
|
key_code tty_keys_next(struct tty *);
|
||||||
|
|
||||||
/* arguments.c */
|
/* arguments.c */
|
||||||
int args_cmp(struct args_entry *, struct args_entry *);
|
|
||||||
RB_PROTOTYPE(args_tree, args_entry, entry, args_cmp);
|
|
||||||
struct args *args_create(int, ...);
|
struct args *args_create(int, ...);
|
||||||
struct args *args_parse(const char *, int, char **);
|
struct args *args_parse(const char *, int, char **);
|
||||||
void args_free(struct args *);
|
void args_free(struct args *);
|
||||||
|
Loading…
Reference in New Issue
Block a user