summaryrefslogtreecommitdiffstats
path: root/session.c
diff options
context:
space:
mode:
authorThomas Adam <thomas@xteddy.org>2016-10-12 09:45:49 +0100
committerThomas Adam <thomas@xteddy.org>2016-10-12 09:45:49 +0100
commitb9dc855016cf79c8bb8469c272dbc6bca24deadc (patch)
treea2049bea7b17ededbd12b77110d47353ed832e46 /session.c
parent27126f87976c63161fcae2ab1eb9c6df726a84ff (diff)
parent5c49e1d0c1afaf98512b2ffd1f31d91fecff9851 (diff)
Merge branch 'obsd-master'
Conflicts: format.c osdep-openbsd.c
Diffstat (limited to 'session.c')
-rw-r--r--session.c32
1 files changed, 18 insertions, 14 deletions
diff --git a/session.c b/session.c
index 12a593f8..da20bab1 100644
--- a/session.c
+++ b/session.c
@@ -26,16 +26,20 @@
#include "tmux.h"
-struct sessions sessions;
-u_int next_session_id;
-struct session_groups session_groups;
+struct sessions sessions;
+static u_int next_session_id;
+struct session_groups session_groups;
-void session_free(int, short, void *);
+static void session_free(int, short, void *);
-void session_lock_timer(int, short, void *);
+static void session_lock_timer(int, short, void *);
-struct winlink *session_next_alert(struct winlink *);
-struct winlink *session_previous_alert(struct winlink *);
+static struct winlink *session_next_alert(struct winlink *);
+static struct winlink *session_previous_alert(struct winlink *);
+
+static void session_group_remove(struct session *);
+static u_int session_group_count(struct session_group *);
+static void session_group_synchronize1(struct session *, struct session *);
RB_GENERATE(sessions, session, entry, session_cmp);
@@ -181,7 +185,7 @@ session_unref(struct session *s)
}
/* Free session. */
-void
+static void
session_free(__unused int fd, __unused short events, void *arg)
{
struct session *s = arg;
@@ -238,7 +242,7 @@ session_check_name(const char *name)
}
/* Lock session if it has timed out. */
-void
+static void
session_lock_timer(__unused int fd, __unused short events, void *arg)
{
struct session *s = arg;
@@ -425,7 +429,7 @@ session_is_linked(struct session *s, struct window *w)
return (w->references != 1);
}
-struct winlink *
+static struct winlink *
session_next_alert(struct winlink *wl)
{
while (wl != NULL) {
@@ -456,7 +460,7 @@ session_next(struct session *s, int alert)
return (session_set_current(s, wl));
}
-struct winlink *
+static struct winlink *
session_previous_alert(struct winlink *wl)
{
while (wl != NULL) {
@@ -581,7 +585,7 @@ session_group_add(struct session *target, struct session *s)
}
/* Remove a session from its group and destroy the group if empty. */
-void
+static void
session_group_remove(struct session *s)
{
struct session_group *sg;
@@ -598,7 +602,7 @@ session_group_remove(struct session *s)
}
/* Count number of sessions in session group. */
-u_int
+static u_int
session_group_count(struct session_group *sg)
{
struct session *s;
@@ -649,7 +653,7 @@ session_group_synchronize_from(struct session *target)
* winlinks then recreating them, then updating the current window, last window
* stack and alerts.
*/
-void
+static void
session_group_synchronize1(struct session *target, struct session *s)
{
struct winlinks old_windows, *ww;