summaryrefslogtreecommitdiffstats
path: root/paste.c
diff options
context:
space:
mode:
authorThomas Adam <thomas@xteddy.org>2016-10-10 16:01:12 +0100
committerThomas Adam <thomas@xteddy.org>2016-10-10 16:01:12 +0100
commit226b6a21929a9ea6b90152aecae4916eae7da005 (patch)
treebfed65379f81cf2abf77d88d6474f190f9573870 /paste.c
parent215d3f8c0d0a604f138b976b2e49ce3fe1a50eb2 (diff)
parent7d4b416fe690b062f02097e95dbb7619a6fb05fe (diff)
Merge branch 'obsd-master'
Diffstat (limited to 'paste.c')
-rw-r--r--paste.c22
1 files changed, 11 insertions, 11 deletions
diff --git a/paste.c b/paste.c
index 1138e8c1..bc2f5c88 100644
--- a/paste.c
+++ b/paste.c
@@ -42,27 +42,27 @@ struct paste_buffer {
RB_ENTRY(paste_buffer) time_entry;
};
-u_int paste_next_index;
-u_int paste_next_order;
-u_int paste_num_automatic;
+static u_int paste_next_index;
+static u_int paste_next_order;
+static u_int paste_num_automatic;
RB_HEAD(paste_name_tree, paste_buffer) paste_by_name;
RB_HEAD(paste_time_tree, paste_buffer) paste_by_time;
-int paste_cmp_names(const struct paste_buffer *, const struct paste_buffer *);
-RB_PROTOTYPE(paste_name_tree, paste_buffer, name_entry, paste_cmp_names);
-RB_GENERATE(paste_name_tree, paste_buffer, name_entry, paste_cmp_names);
+static int paste_cmp_names(const struct paste_buffer *,
+ const struct paste_buffer *);
+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 *);
-RB_PROTOTYPE(paste_time_tree, paste_buffer, time_entry, paste_cmp_times);
-RB_GENERATE(paste_time_tree, paste_buffer, time_entry, paste_cmp_times);
+static int paste_cmp_times(const struct paste_buffer *,
+ const struct paste_buffer *);
+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)
{
return (strcmp(a->name, b->name));
}
-int
+static int
paste_cmp_times(const struct paste_buffer *a, const struct paste_buffer *b)
{
if (a->order > b->order)